diff options
author | James Peach <jpeach@samba.org> | 2007-11-21 18:31:35 -0800 |
---|---|---|
committer | James Peach <jpeach@samba.org> | 2007-11-21 18:31:35 -0800 |
commit | 64b54e534008a1ac36b9ba21726ca0954fe00d63 (patch) | |
tree | 5a5e0f42c70d4afa14ba689bf4f97af321432510 /source3/rpc_client/cli_pipe.c | |
parent | febaaae2021c2993d265cc48cf9fbef05cb4ed1b (diff) | |
parent | 7ef6c19074495110d5c0b698b05c4ee52a0744d6 (diff) | |
download | samba-64b54e534008a1ac36b9ba21726ca0954fe00d63.tar.gz samba-64b54e534008a1ac36b9ba21726ca0954fe00d63.tar.xz samba-64b54e534008a1ac36b9ba21726ca0954fe00d63.zip |
Merge ssh://git.samba.org/data/git/samba into v3-2-test
(This used to be commit 660ea443364e949ed06c28b00f0e1c3757f0da27)
Diffstat (limited to 'source3/rpc_client/cli_pipe.c')
-rw-r--r-- | source3/rpc_client/cli_pipe.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c index 1e5e04448f..c93e26ccbc 100644 --- a/source3/rpc_client/cli_pipe.c +++ b/source3/rpc_client/cli_pipe.c @@ -1551,13 +1551,15 @@ NTSTATUS rpc_api_pipe_req(struct rpc_pipe_client *cli, ret = rpc_api_pipe(cli, &outgoing_pdu, out_data, RPC_RESPONSE); prs_mem_free(&outgoing_pdu); - if (DEBUGLEVEL >= 50) { - pstring dump_name; + char *dump_name = NULL; /* Also capture received data */ - slprintf(dump_name, sizeof(dump_name) - 1, "%s/reply_%s_%d", - dyn_LOGFILEBASE, cli->pipe_name, op_num); - prs_dump(dump_name, op_num, out_data); + if (asprintf(&dump_name, "%s/reply_%s_%d", + dyn_LOGFILEBASE, cli->pipe_name, + op_num) > 0) { + prs_dump(dump_name, op_num, out_data); + SAFE_FREE(dump_name); + } } return ret; |