Zebediah Figura : rpcrt4/tests: Pass the default maximum call limit to RpcServerListen().

Alexandre Julliard julliard at winehq.org
Wed Jan 15 16:26:47 CST 2020


Module: wine
Branch: master
Commit: c2b4d98f23f5007ad7da2083afd78ec411155a5f
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=c2b4d98f23f5007ad7da2083afd78ec411155a5f

Author: Zebediah Figura <z.figura12 at gmail.com>
Date:   Tue Jan 14 19:18:23 2020 -0600

rpcrt4/tests: Pass the default maximum call limit to RpcServerListen().

The tests intermittently crash on 2008 with RPC_S_SERVER_TOO_BUSY.  I suspect
this is due to the server spawned in run_server having a call limit of 20 but
being expected to service 32 threads.  Use the default parameter in an attempt
to prevent this failure.

Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/rpcrt4/tests/server.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/dlls/rpcrt4/tests/server.c b/dlls/rpcrt4/tests/server.c
index a07e2f1787..0a76c96d58 100644
--- a/dlls/rpcrt4/tests/server.c
+++ b/dlls/rpcrt4/tests/server.c
@@ -2049,7 +2049,7 @@ server(void)
     ok(status == RPC_S_OK, "RpcServerRegisterIf failed with status %d\n", status);
   }
   test_is_server_listening(NULL, RPC_S_NOT_LISTENING);
-  status = RpcServerListen(1, 20, TRUE);
+  status = RpcServerListen(1, RPC_C_LISTEN_MAX_CALLS_DEFAULT, TRUE);
   ok(status == RPC_S_OK, "RpcServerListen failed with status %d\n", status);
   test_is_server_listening(NULL, RPC_S_OK);
   stop_event = CreateEventW(NULL, FALSE, FALSE, NULL);
@@ -2146,7 +2146,7 @@ static void test_stop_wait_for_call(unsigned char *binding)
     RPC_STATUS status;
     DWORD ret;
 
-    status = RpcServerListen(1, 20, TRUE);
+    status = RpcServerListen(1, RPC_C_LISTEN_MAX_CALLS_DEFAULT, TRUE);
     ok(status == RPC_S_OK, "RpcServerListen failed with status %d\n", status);
     test_is_server_listening(NULL, RPC_S_OK);
 
@@ -2202,11 +2202,11 @@ static void test_server_listening(void)
     ok(status == RPC_S_OK, "RpcServerRegisterIf failed with status %d\n", status);
 
     test_is_server_listening(NULL, RPC_S_NOT_LISTENING);
-    status = RpcServerListen(1, 20, TRUE);
+    status = RpcServerListen(1, RPC_C_LISTEN_MAX_CALLS_DEFAULT, TRUE);
     ok(status == RPC_S_OK, "RpcServerListen failed with status %d\n", status);
     test_is_server_listening(NULL, RPC_S_OK);
 
-    status = RpcServerListen(1, 20, TRUE);
+    status = RpcServerListen(1, RPC_C_LISTEN_MAX_CALLS_DEFAULT, TRUE);
     ok(status == RPC_S_ALREADY_LISTENING, "RpcServerListen failed with status %d\n", status);
 
     status = RpcMgmtStopServerListening(NULL);
@@ -2281,7 +2281,7 @@ static void run_server(HANDLE ready_event)
     ok(status == RPC_S_OK, "RpcServerRegisterIf failed with status %d\n", status);
 
     test_is_server_listening(NULL, RPC_S_NOT_LISTENING);
-    status = RpcServerListen(1, 20, TRUE);
+    status = RpcServerListen(1, RPC_C_LISTEN_MAX_CALLS_DEFAULT, TRUE);
     ok(status == RPC_S_OK, "RpcServerListen failed with status %d\n", status);
 
     stop_event = CreateEventW(NULL, FALSE, FALSE, NULL);




More information about the wine-cvs mailing list