diff options
author | Kamen Mazdrashki <kamen.mazdrashki@postpath.com> | 2009-11-14 15:51:53 +0200 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2009-11-17 10:46:59 +1100 |
commit | aaff29f5b472468e0ffbfc9bf33eead16bdb111c (patch) | |
tree | 34bb486fa3866d8f6c67d3b29fb50786d3bdc797 /source4/torture | |
parent | 673049142b9f5e002ddbae7b3aeb051b0a6ecdc2 (diff) | |
download | samba-aaff29f5b472468e0ffbfc9bf33eead16bdb111c.tar.gz samba-aaff29f5b472468e0ffbfc9bf33eead16bdb111c.tar.bz2 samba-aaff29f5b472468e0ffbfc9bf33eead16bdb111c.zip |
s4/drs(tort): use torture_drsuapi_assert_call() macro for error checking
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source4/torture')
-rw-r--r-- | source4/torture/rpc/dssync.c | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/source4/torture/rpc/dssync.c b/source4/torture/rpc/dssync.c index 7d8dc9216a..ab17359ae5 100644 --- a/source4/torture/rpc/dssync.c +++ b/source4/torture/rpc/dssync.c @@ -875,17 +875,8 @@ static bool test_FetchData(struct torture_context *tctx, struct DsSyncTest *ctx) } status = dcerpc_drsuapi_DsGetNCChanges(ctx->new_dc.drsuapi.drs_pipe, ctx, &r); - if (!NT_STATUS_IS_OK(status)) { - const char *errstr = nt_errstr(status); - if (NT_STATUS_EQUAL(status, NT_STATUS_NET_WRITE_FAULT)) { - errstr = dcerpc_errstr(ctx, ctx->new_dc.drsuapi.drs_pipe->last_fault_code); - } - printf("dcerpc_drsuapi_DsGetNCChanges failed - %s\n", errstr); - ret = false; - } else if (!W_ERROR_IS_OK(r.out.result)) { - printf("DsGetNCChanges failed - %s\n", win_errstr(r.out.result)); - ret = false; - } + torture_drsuapi_assert_call(tctx, ctx->new_dc.drsuapi.drs_pipe, status, + &r, "dcerpc_drsuapi_DsGetNCChanges"); if (ret == true && *r.out.level_out == 1) { out_level = 1; |