summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2005-11-19 10:40:31 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:46:30 -0500
commitbd69407be6b858aec9b2955914d210efc1a77194 (patch)
tree35643c87822721c17e639c2d93ed17b1abc038d5 /source4
parentfc04e3e795cebca5723c24e097f5374a23b2247b (diff)
downloadsamba-bd69407be6b858aec9b2955914d210efc1a77194.tar.gz
samba-bd69407be6b858aec9b2955914d210efc1a77194.tar.bz2
samba-bd69407be6b858aec9b2955914d210efc1a77194.zip
r11802: - add copyright
- fix crash bug when running as non root - add extra comments in the output metze (This used to be commit ffc3cd73474722d60a781fb758105f665e73c0ca)
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/nbt/winsreplication.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/source4/torture/nbt/winsreplication.c b/source4/torture/nbt/winsreplication.c
index 032983bcd1..3619309ce3 100644
--- a/source4/torture/nbt/winsreplication.c
+++ b/source4/torture/nbt/winsreplication.c
@@ -3,7 +3,8 @@
WINS replication testing
- Copyright (C) Andrew Tridgell 2005
+ Copyright (C) Andrew Tridgell 2005
+ Copyright (C) Stefan Metzmacher 2005
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -483,7 +484,7 @@ static struct test_wrepl_conflict_conn *test_create_conflict_ctx(TALLOC_CTX *mem
ctx->nbtsock_srv = NULL;
}
- if (ctx->myaddr2) {
+ if (ctx->myaddr2 && ctx->nbtsock_srv) {
ctx->nbtsock2 = nbt_name_socket_init(ctx, NULL);
if (!ctx->nbtsock2) return NULL;
@@ -1007,6 +1008,7 @@ static BOOL test_conflict_different_owner(struct test_wrepl_conflict_conn *ctx)
struct {
const char *line; /* just better debugging */
struct nbt_name name;
+ const char *comment;
BOOL extra; /* not the worst case, this is an extra test */
BOOL cleanup;
struct {
@@ -3747,6 +3749,7 @@ static BOOL test_conflict_different_owner(struct test_wrepl_conflict_conn *ctx)
{
.line = __location__,
.name = _NBT_NAME("_DIFF_OWNER", 0x00, NULL),
+ .comment= "but owner changed",
.extra = True,
.r1 = {
.owner = &ctx->a,
@@ -3873,14 +3876,17 @@ static BOOL test_conflict_different_owner(struct test_wrepl_conflict_conn *ctx)
ips = "different";
}
- printf("%s,%s%s vs. %s,%s%s with %s ip(s) => %s\n",
+ printf("%s,%s%s vs. %s,%s%s with %s ip(s)%s%s => %s\n",
wrepl_name_type_string(records[i].r1.type),
wrepl_name_state_string(records[i].r1.state),
(records[i].r1.is_static?",static":""),
wrepl_name_type_string(records[i].r2.type),
wrepl_name_state_string(records[i].r2.state),
(records[i].r2.is_static?",static":""),
- ips, expected);
+ ips,
+ (records[i].comment?" ":""),
+ (records[i].comment?records[i].comment:""),
+ expected);
}
/*