s4/test: Fix incorrect NTSTATUS comparison
authorKamen Mazdrashki <kamenim@samba.org>
Wed, 9 Jun 2010 22:59:51 +0000 (01:59 +0300)
committerKamen Mazdrashki <kamenim@samba.org>
Thu, 10 Jun 2010 22:20:09 +0000 (01:20 +0300)
In case group already exists, we should get NT_STATUS_GROUP_EXISTS.

source4/torture/libnet/utils.c

index 4c4499cc817d0f17db31c828038fc3058d16b513..dfc5923f2aa90b7b9a08db9f32df93640f10c290 100644 (file)
@@ -385,8 +385,8 @@ bool test_group_create(struct torture_context *tctx,
        if (!NT_STATUS_IS_OK(r.out.result)) {
                torture_comment(tctx, "CreateGroup failed - %s\n", nt_errstr(r.out.result));
 
-               if (NT_STATUS_EQUAL(r.out.result, NT_STATUS_USER_EXISTS)) {
-                       torture_comment(tctx, "Group (%s) already exists - attempting to delete and recreate account again\n", name);
+               if (NT_STATUS_EQUAL(r.out.result, NT_STATUS_GROUP_EXISTS)) {
+                       torture_comment(tctx, "Group (%s) already exists - attempting to delete and recreate group again\n", name);
                        if (!test_group_cleanup(tctx, b, mem_ctx, handle, name)) {
                                return false;
                        }