summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2006-05-26 04:35:37 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:08:38 -0500
commit72209db1a1f76a1ded0e77a9ab4619836f78b529 (patch)
treead5e3ddf87f97668e4730db23af98db4d4bb3a16 /source4
parentd6ac0e7d2f22f162eaf1bbc9cca9b1e99194c97b (diff)
downloadsamba-72209db1a1f76a1ded0e77a9ab4619836f78b529.tar.gz
samba-72209db1a1f76a1ded0e77a9ab4619836f78b529.tar.bz2
samba-72209db1a1f76a1ded0e77a9ab4619836f78b529.zip
r15898: use d_printf() in some more places to fix more torture seg faults on
solaris (This used to be commit dd1ef82560c62c8c10e9d43b8d1d68512fe0aae5)
Diffstat (limited to 'source4')
-rw-r--r--source4/torture/libnet/libnet_rpc.c46
-rw-r--r--source4/torture/rpc/netlogon.c14
2 files changed, 30 insertions, 30 deletions
diff --git a/source4/torture/libnet/libnet_rpc.c b/source4/torture/libnet/libnet_rpc.c
index 4a394c58d2..30c1438e38 100644
--- a/source4/torture/libnet/libnet_rpc.c
+++ b/source4/torture/libnet/libnet_rpc.c
@@ -56,7 +56,7 @@ static BOOL test_connect_service(struct libnet_context *ctx,
status = libnet_RpcConnect(ctx, ctx, &connect);
if (!NT_STATUS_EQUAL(status, expected_status)) {
- printf("Connecting to rpc service %s on %s.\n\tFAILED. Expected: %s."
+ d_printf("Connecting to rpc service %s on %s.\n\tFAILED. Expected: %s."
"Received: %s\n",
connect.in.dcerpc_iface->name, connect.in.binding, nt_errstr(expected_status),
nt_errstr(status));
@@ -64,18 +64,18 @@ static BOOL test_connect_service(struct libnet_context *ctx,
return False;
}
- printf("PASSED. Expected: %s, received: %s\n", nt_errstr(expected_status),
+ d_printf("PASSED. Expected: %s, received: %s\n", nt_errstr(expected_status),
nt_errstr(status));
if (connect.level == LIBNET_RPC_CONNECT_DC_INFO && NT_STATUS_IS_OK(status)) {
- printf("Domain Controller Info:\n");
- printf("\tDomain Name:\t %s\n", connect.out.domain_name);
- printf("\tDomain SID:\t %s\n", dom_sid_string(ctx, connect.out.domain_sid));
- printf("\tRealm:\t\t %s\n", connect.out.realm);
- printf("\tGUID:\t\t %s\n", GUID_string(ctx, connect.out.guid));
+ d_printf("Domain Controller Info:\n");
+ d_printf("\tDomain Name:\t %s\n", connect.out.domain_name);
+ d_printf("\tDomain SID:\t %s\n", dom_sid_string(ctx, connect.out.domain_sid));
+ d_printf("\tRealm:\t\t %s\n", connect.out.realm);
+ d_printf("\tGUID:\t\t %s\n", GUID_string(ctx, connect.out.guid));
} else if (!NT_STATUS_IS_OK(status)) {
- printf("Error string: %s\n", connect.out.error_string);
+ d_printf("Error string: %s\n", connect.out.error_string);
}
return True;
@@ -91,38 +91,38 @@ static BOOL torture_rpc_connect(struct torture_context *torture,
ctx = libnet_context_init(NULL);
ctx->cred = cmdline_credentials;
- printf("Testing connection to LSA interface\n");
+ d_printf("Testing connection to LSA interface\n");
if (!test_connect_service(ctx, &dcerpc_table_lsarpc, bindstr,
hostname, level, False, NT_STATUS_OK)) {
- printf("failed to connect LSA interface\n");
+ d_printf("failed to connect LSA interface\n");
return False;
}
- printf("Testing connection to SAMR interface\n");
+ d_printf("Testing connection to SAMR interface\n");
if (!test_connect_service(ctx, &dcerpc_table_samr, bindstr,
hostname, level, False, NT_STATUS_OK)) {
- printf("failed to connect SAMR interface\n");
+ d_printf("failed to connect SAMR interface\n");
return False;
}
- printf("Testing connection to SRVSVC interface\n");
+ d_printf("Testing connection to SRVSVC interface\n");
if (!test_connect_service(ctx, &dcerpc_table_srvsvc, bindstr,
hostname, level, False, NT_STATUS_OK)) {
- printf("failed to connect SRVSVC interface\n");
+ d_printf("failed to connect SRVSVC interface\n");
return False;
}
- printf("Testing connection to LSA interface with wrong credentials\n");
+ d_printf("Testing connection to LSA interface with wrong credentials\n");
if (!test_connect_service(ctx, &dcerpc_table_lsarpc, bindstr,
hostname, level, True, NT_STATUS_LOGON_FAILURE)) {
- printf("failed to test wrong credentials on LSA interface\n");
+ d_printf("failed to test wrong credentials on LSA interface\n");
return False;
}
- printf("Testing connection to SAMR interface with wrong credentials\n");
+ d_printf("Testing connection to SAMR interface with wrong credentials\n");
if (!test_connect_service(ctx, &dcerpc_table_samr, bindstr,
hostname, level, True, NT_STATUS_LOGON_FAILURE)) {
- printf("failed to test wrong credentials on SAMR interface\n");
+ d_printf("failed to test wrong credentials on SAMR interface\n");
return False;
}
@@ -142,7 +142,7 @@ BOOL torture_rpc_connect_srv(struct torture_context *torture)
bindstr = lp_parm_string(-1, "torture", "binding");
status = dcerpc_parse_binding(torture, bindstr, &binding);
if (!NT_STATUS_IS_OK(status)) {
- printf("failed to parse binding string\n");
+ d_printf("failed to parse binding string\n");
return False;
}
@@ -160,7 +160,7 @@ BOOL torture_rpc_connect_pdc(struct torture_context *torture)
bindstr = lp_parm_string(-1, "torture", "binding");
status = dcerpc_parse_binding(torture, bindstr, &binding);
if (!NT_STATUS_IS_OK(status)) {
- printf("failed to parse binding string\n");
+ d_printf("failed to parse binding string\n");
return False;
}
@@ -178,7 +178,7 @@ BOOL torture_rpc_connect_dc(struct torture_context *torture)
bindstr = lp_parm_string(-1, "torture", "binding");
status = dcerpc_parse_binding(torture, bindstr, &binding);
if (!NT_STATUS_IS_OK(status)) {
- printf("failed to parse binding string\n");
+ d_printf("failed to parse binding string\n");
return False;
}
@@ -196,7 +196,7 @@ BOOL torture_rpc_connect_dc_info(struct torture_context *torture)
bindstr = lp_parm_string(-1, "torture", "binding");
status = dcerpc_parse_binding(torture, bindstr, &binding);
if (!NT_STATUS_IS_OK(status)) {
- printf("failed to parse binding string\n");
+ d_printf("failed to parse binding string\n");
return False;
}
@@ -214,7 +214,7 @@ BOOL torture_rpc_connect_binding(struct torture_context *torture)
bindstr = lp_parm_string(-1, "torture", "binding");
status = dcerpc_parse_binding(torture, bindstr, &binding);
if (!NT_STATUS_IS_OK(status)) {
- printf("failed to parse binding string\n");
+ d_printf("failed to parse binding string\n");
return False;
}
diff --git a/source4/torture/rpc/netlogon.c b/source4/torture/rpc/netlogon.c
index b66ea719cc..71bd8b097f 100644
--- a/source4/torture/rpc/netlogon.c
+++ b/source4/torture/rpc/netlogon.c
@@ -305,7 +305,7 @@ static BOOL test_SetPassword(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
creds_des_encrypt(creds, &r.in.new_password);
printf("Testing ServerPasswordSet on machine account\n");
- printf("Changing machine account password to '%s'\n", password);
+ d_printf("Changing machine account password to '%s'\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -324,7 +324,7 @@ static BOOL test_SetPassword(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
allows the password to be set to the same value twice in a
row (match win2k3) */
printf("Testing a second ServerPasswordSet on machine account\n");
- printf("Changing machine account password to '%s' (same as previous run)\n", password);
+ d_printf("Changing machine account password to '%s' (same as previous run)\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -377,7 +377,7 @@ static BOOL test_SetPassword2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
r.in.new_password.length = IVAL(password_buf.data, 512);
printf("Testing ServerPasswordSet2 on machine account\n");
- printf("Changing machine account password to '%s'\n", password);
+ d_printf("Changing machine account password to '%s'\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -409,7 +409,7 @@ static BOOL test_SetPassword2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
r.in.new_password.length = IVAL(password_buf.data, 512);
printf("Testing ServerPasswordSet2 on machine account\n");
- printf("Changing machine account password to '%s'\n", password);
+ d_printf("Changing machine account password to '%s'\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -440,7 +440,7 @@ static BOOL test_SetPassword2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
r.in.new_password.length = IVAL(password_buf.data, 512);
printf("Testing second ServerPasswordSet2 on machine account\n");
- printf("Changing machine account password to '%s'\n", password);
+ d_printf("Changing machine account password to '%s'\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -459,7 +459,7 @@ static BOOL test_SetPassword2(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx)
allows the password to be set to the same value twice in a
row (match win2k3) */
printf("Testing a second ServerPasswordSet2 on machine account\n");
- printf("Changing machine account password to '%s' (same as previous run)\n", password);
+ d_printf("Changing machine account password to '%s' (same as previous run)\n", password);
creds_client_authenticator(creds, &r.in.credential);
@@ -548,7 +548,7 @@ BOOL test_netlogon_ops(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx,
r.in.logon_level = 2;
r.in.logon.network = &ninfo;
- printf("Testing LogonSamLogon with name %s\n", ninfo.identity_info.account_name.string);
+ d_printf("Testing LogonSamLogon with name %s\n", ninfo.identity_info.account_name.string);
for (i=2;i<3;i++) {
ZERO_STRUCT(auth2);