summaryrefslogtreecommitdiffstats
path: root/source4/lib/messaging
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2014-05-05 16:27:59 +1200
committerStefan Metzmacher <metze@samba.org>2014-05-13 00:08:12 +0200
commita20c7e6adb43b494654e237709e9dc63446ac7b9 (patch)
treef06eb4069166a28adf664b0327a0fb15701fa402 /source4/lib/messaging
parent6cbf3ecd6669f73d9a1b64118956b49439de74bc (diff)
downloadsamba-a20c7e6adb43b494654e237709e9dc63446ac7b9.tar.gz
samba-a20c7e6adb43b494654e237709e9dc63446ac7b9.tar.xz
samba-a20c7e6adb43b494654e237709e9dc63446ac7b9.zip
s4:irpc/tests: explicitly use dcerpc_binding_handle_set_sync_ev()
This indicates that we're using nested event loops... Andrew Bartlett Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Change-Id: I17d530a1f338cfdbd2e4e755b6f01a44a3e7ba7a Signed-off-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source4/lib/messaging')
-rw-r--r--source4/lib/messaging/tests/irpc.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source4/lib/messaging/tests/irpc.c b/source4/lib/messaging/tests/irpc.c
index d78dc78492..486420b50d 100644
--- a/source4/lib/messaging/tests/irpc.c
+++ b/source4/lib/messaging/tests/irpc.c
@@ -102,6 +102,11 @@ static bool test_addone(struct torture_context *test, const void *_data,
r.in.in_data = value;
test_debug = true;
+ /*
+ * Note: this makes use of nested event loops
+ * as client and server use the same loop.
+ */
+ dcerpc_binding_handle_set_sync_ev(irpc_handle, data->ev);
status = dcerpc_echo_AddOne_r(irpc_handle, test, &r);
test_debug = false;
torture_assert_ntstatus_ok(test, status, "AddOne failed");
@@ -136,6 +141,11 @@ static bool test_echodata(struct torture_context *tctx,
r.in.in_data = (unsigned char *)talloc_strdup(mem_ctx, "0123456789");
r.in.len = strlen((char *)r.in.in_data);
+ /*
+ * Note: this makes use of nested event loops
+ * as client and server use the same loop.
+ */
+ dcerpc_binding_handle_set_sync_ev(irpc_handle, data->ev);
status = dcerpc_echo_EchoData_r(irpc_handle, mem_ctx, &r);
torture_assert_ntstatus_ok(tctx, status, "EchoData failed");