summaryrefslogtreecommitdiff
path: root/source4/torture/rpc
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-02-27 10:02:40 +0100
committerStefan Metzmacher <metze@samba.org>2010-03-01 16:11:58 +0100
commit719cecba848b3e446ea3bc06f14cf90e9cddab9e (patch)
treefc56aa3c49b03b8eae0b347cfc5417e4b9b8c0c6 /source4/torture/rpc
parent22b1e0bf324113db12e40567cc1cb9d645049681 (diff)
downloadsamba-719cecba848b3e446ea3bc06f14cf90e9cddab9e.tar.gz
samba-719cecba848b3e446ea3bc06f14cf90e9cddab9e.tar.bz2
samba-719cecba848b3e446ea3bc06f14cf90e9cddab9e.zip
s4:RPC-NETLOGON: remove useless rpc callback
If we got a failure from one request we bail out early. metze
Diffstat (limited to 'source4/torture/rpc')
-rw-r--r--source4/torture/rpc/netlogon.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/source4/torture/rpc/netlogon.c b/source4/torture/rpc/netlogon.c
index 091f48a9c0..c7bfb94e9d 100644
--- a/source4/torture/rpc/netlogon.c
+++ b/source4/torture/rpc/netlogon.c
@@ -2629,15 +2629,6 @@ static bool test_GetDomainInfo(struct torture_context *tctx,
return true;
}
-
-static void async_callback(struct rpc_request *req)
-{
- int *counter = (int *)req->async.private_data;
- if (NT_STATUS_IS_OK(req->status)) {
- (*counter)++;
- }
-}
-
static bool test_GetDomainInfo_async(struct torture_context *tctx,
struct dcerpc_pipe *p,
struct cli_credentials *machine_credentials)
@@ -2651,7 +2642,6 @@ static bool test_GetDomainInfo_async(struct torture_context *tctx,
struct netlogon_creds_CredentialState *creds_async[ASYNC_COUNT];
struct rpc_request *req[ASYNC_COUNT];
int i;
- int *async_counter = talloc(tctx, int);
union netr_WorkstationInfo query;
union netr_DomainInfo info;
@@ -2680,17 +2670,12 @@ static bool test_GetDomainInfo_async(struct torture_context *tctx,
query.workstation_info = &q1;
- *async_counter = 0;
-
for (i=0;i<ASYNC_COUNT;i++) {
netlogon_creds_client_authenticator(creds, &a);
creds_async[i] = (struct netlogon_creds_CredentialState *)talloc_memdup(creds, creds, sizeof(*creds));
req[i] = dcerpc_netr_LogonGetDomainInfo_send(p, tctx, &r);
- req[i]->async.callback = async_callback;
- req[i]->async.private_data = async_counter;
-
/* even with this flush per request a w2k3 server seems to
clag with multiple outstanding requests. bleergh. */
torture_assert_int_equal(tctx, event_loop_once(dcerpc_event_context(p)), 0,
@@ -2708,9 +2693,7 @@ static bool test_GetDomainInfo_async(struct torture_context *tctx,
}
torture_comment(tctx,
- "Testing netr_LogonGetDomainInfo - async count %d OK\n", *async_counter);
-
- torture_assert_int_equal(tctx, (*async_counter), ASYNC_COUNT, "int");
+ "Testing netr_LogonGetDomainInfo - async count %d OK\n", ASYNC_COUNT);
return true;
}