summaryrefslogtreecommitdiff
path: root/source4/libcli/rap
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2011-12-16 11:26:54 +0100
committerStefan Metzmacher <metze@samba.org>2011-12-16 13:11:42 +0100
commit35605fa0a3c44f1d8da2c06c1b17170aeca2bbef (patch)
tree026df2b359e2c3c1a8eb8f8400ca2ff196af6a67 /source4/libcli/rap
parent0e04cc2ea4b19ec024c9839ec93e99e417064174 (diff)
downloadsamba-35605fa0a3c44f1d8da2c06c1b17170aeca2bbef.tar.gz
samba-35605fa0a3c44f1d8da2c06c1b17170aeca2bbef.tar.bz2
samba-35605fa0a3c44f1d8da2c06c1b17170aeca2bbef.zip
s4:libcli/rap: the caller should get talloc children from call->ndr_pull_{param,data}
This should fix the flakey 'rap.printing.rap_printq_getinfo' test, see https://git.samba.org/autobuild.flakey/2011-12-16-0022/samba4.stdout metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Fri Dec 16 13:11:42 CET 2011 on sn-devel-104
Diffstat (limited to 'source4/libcli/rap')
-rw-r--r--source4/libcli/rap/rap.c5
-rw-r--r--source4/libcli/rap/rap.h2
2 files changed, 6 insertions, 1 deletions
diff --git a/source4/libcli/rap/rap.c b/source4/libcli/rap/rap.c
index e08a650355..1eee811f7f 100644
--- a/source4/libcli/rap/rap.c
+++ b/source4/libcli/rap/rap.c
@@ -44,6 +44,8 @@ struct rap_call *new_rap_cli_call(TALLOC_CTX *mem_ctx, uint16_t callno)
call->ndr_push_data = ndr_push_init_ctx(call);
call->ndr_push_data->flags = RAPNDR_FLAGS;
+ call->pull_mem_ctx = mem_ctx;
+
return call;
}
@@ -217,9 +219,10 @@ NTSTATUS rap_cli_do_call(struct smbcli_tree *tree,
call->ndr_pull_param = ndr_pull_init_blob(&trans.out.params, call);
call->ndr_pull_param->flags = RAPNDR_FLAGS;
-
+ call->ndr_pull_param->current_mem_ctx = call->pull_mem_ctx;
call->ndr_pull_data = ndr_pull_init_blob(&trans.out.data, call);
call->ndr_pull_data->flags = RAPNDR_FLAGS;
+ call->ndr_pull_data->current_mem_ctx = call->pull_mem_ctx;
return result;
}
diff --git a/source4/libcli/rap/rap.h b/source4/libcli/rap/rap.h
index c611f001f1..1d44682750 100644
--- a/source4/libcli/rap/rap.h
+++ b/source4/libcli/rap/rap.h
@@ -64,6 +64,8 @@ struct rap_call {
struct ndr_push *ndr_push_param;
struct ndr_push *ndr_push_data;
+
+ TALLOC_CTX *pull_mem_ctx;
struct ndr_pull *ndr_pull_param;
struct ndr_pull *ndr_pull_data;
};