summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2005-12-05 10:15:56 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:47:04 -0500
commitbf6ac478483b90c72d78168e4b721ab5efa2a3ab (patch)
treec79aef0a9ef91dff66177f4243cdc843f05ec292 /source4/torture
parent7ab5c74a9898091f81df8a93092f4165506ccade (diff)
downloadsamba-bf6ac478483b90c72d78168e4b721ab5efa2a3ab.tar.gz
samba-bf6ac478483b90c72d78168e4b721ab5efa2a3ab.tar.bz2
samba-bf6ac478483b90c72d78168e4b721ab5efa2a3ab.zip
r12068: a better fix to prevent crashing, on errors
metze (This used to be commit 7b20f8e66d55774877ec1441175fb707856c6609)
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/nbt/winsreplication.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/source4/torture/nbt/winsreplication.c b/source4/torture/nbt/winsreplication.c
index 6bf25146fe..4ca9ed77cd 100644
--- a/source4/torture/nbt/winsreplication.c
+++ b/source4/torture/nbt/winsreplication.c
@@ -1096,8 +1096,6 @@ static BOOL test_conflict_same_owner(struct test_wrepl_conflict_conn *ctx)
}
};
- if (!ctx) return False;
-
name.name = "_SAME_OWNER_A";
name.type = 0;
name.scope = NULL;
@@ -4634,8 +4632,6 @@ static BOOL test_conflict_different_owner(struct test_wrepl_conflict_conn *ctx)
}
}}; /* do not add entries here, this should be the last record! */
- if (!ctx) return False;
-
wins_name_r1 = &wins_name1;
wins_name_r2 = &wins_name2;
@@ -6385,8 +6381,6 @@ static BOOL test_conflict_owned_released_vs_replica(struct test_wrepl_conflict_c
},
};
- if (!ctx) return False;
-
printf("Test Replica records vs. owned released records\n");
for(i=0; ret && i < ARRAY_SIZE(records); i++) {
@@ -9018,8 +9012,6 @@ static BOOL test_conflict_owned_active_vs_replica(struct test_wrepl_conflict_con
},
};
- if (!ctx) return False;
-
if (!ctx->nbtsock_srv) {
printf("SKIP: Test Replica records vs. owned active records: not bound to port[%d]\n",
lp_nbt_port());
@@ -9511,6 +9503,7 @@ BOOL torture_nbt_winsreplication_quick(void)
ret &= test_wins_replication(mem_ctx, address);
ctx = test_create_conflict_ctx(mem_ctx, address);
+ if (!ctx) return False;
ret &= test_conflict_same_owner(ctx);
ret &= test_conflict_owned_released_vs_replica(ctx);
@@ -9549,6 +9542,7 @@ BOOL torture_nbt_winsreplication(void)
ret &= test_wins_replication(mem_ctx, address);
ctx = test_create_conflict_ctx(mem_ctx, address);
+ if (!ctx) return False;
ret &= test_conflict_same_owner(ctx);
ret &= test_conflict_different_owner(ctx);