summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2003-12-17 02:35:04 +0000
committerAndrew Tridgell <tridge@samba.org>2003-12-17 02:35:04 +0000
commitaa4aa0f99f81ea9eb9c3bfefafe8faa2b4b44c83 (patch)
tree10508eac6a31f357f9ffb3b3412b2d4e2ddb5e57 /source4/torture
parentf9b522cfada29f3b0116a059d242b0c30ee6aaad (diff)
downloadsamba-aa4aa0f99f81ea9eb9c3bfefafe8faa2b4b44c83.tar.gz
samba-aa4aa0f99f81ea9eb9c3bfefafe8faa2b4b44c83.tar.bz2
samba-aa4aa0f99f81ea9eb9c3bfefafe8faa2b4b44c83.zip
fixed a bug in the acct_flags checking on CreateUser2 in the RPC-SAMR test
(This used to be commit 2c9a999c5421a07ae3059595f70d5533f2040a03)
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/rpc/samr.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source4/torture/rpc/samr.c b/source4/torture/rpc/samr.c
index 7ccdc321ce..2678f38254 100644
--- a/source4/torture/rpc/samr.c
+++ b/source4/torture/rpc/samr.c
@@ -330,7 +330,7 @@ static BOOL test_CreateUser(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
}
- q.in.handle = handle;
+ q.in.handle = &acct_handle;
q.in.level = 16;
status = dcerpc_samr_QueryUserInfo(p, mem_ctx, &q);
@@ -339,7 +339,7 @@ static BOOL test_CreateUser(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
q.in.level, nt_errstr(status));
ret = False;
} else {
- if (q.out.info->info16.acct_flags != acct_flags) {
+ if ((q.out.info->info16.acct_flags & acct_flags) != acct_flags) {
printf("QuerUserInfo level 16 failed, it returned 0x%08x (%u) when we expected flags of 0x%08x (%u)\n",
q.out.info->info16.acct_flags, q.out.info->info16.acct_flags,
acct_flags, acct_flags);
@@ -436,7 +436,7 @@ static BOOL test_CreateUser2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
}
if (NT_STATUS_IS_OK(status)) {
- q.in.handle = handle;
+ q.in.handle = &acct_handle;
q.in.level = 16;
status = dcerpc_samr_QueryUserInfo(p, mem_ctx, &q);
@@ -445,8 +445,8 @@ static BOOL test_CreateUser2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
q.in.level, nt_errstr(status));
ret = False;
} else {
- if (q.out.info->info16.acct_flags != acct_flags) {
- printf("QuerUserInfo level 16 failed, it returned 0x%08xwhen we expected flags of 0x%08x\n",
+ if ((q.out.info->info16.acct_flags & acct_flags) != acct_flags) {
+ printf("QuerUserInfo level 16 failed, it returned 0x%08x when we expected flags of 0x%08x\n",
q.out.info->info16.acct_flags,
acct_flags);
ret = False;