summaryrefslogtreecommitdiff
path: root/pidl/lib
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-04-17 13:04:18 +0200
committerStefan Metzmacher <metze@samba.org>2009-04-20 18:15:01 +0200
commited98cba5ab8f585bc83e732fd61a2c04c48c0607 (patch)
treed4948410390bf33b4b84d802389cf11262c82fd2 /pidl/lib
parentd0e68032187d7167d535d710f01a1c84ac006f3c (diff)
downloadsamba-ed98cba5ab8f585bc83e732fd61a2c04c48c0607.tar.gz
samba-ed98cba5ab8f585bc83e732fd61a2c04c48c0607.tar.bz2
samba-ed98cba5ab8f585bc83e732fd61a2c04c48c0607.zip
pidl:Samba4/client: use dcerpc_ndr_request() for sync requests
metze
Diffstat (limited to 'pidl/lib')
-rw-r--r--pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm12
1 files changed, 7 insertions, 5 deletions
diff --git a/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm b/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
index f2a96a3037..cb2c752aca 100644
--- a/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
@@ -45,6 +45,7 @@ sub ParseFunctionSend($$$)
sub ParseFunctionSync($$$)
{
my ($interface, $fn, $name) = @_;
+ my $uname = uc $name;
my $proto = "NTSTATUS dcerpc_$name(struct dcerpc_pipe *p, TALLOC_CTX *mem_ctx, struct $name *r)";
@@ -55,13 +56,14 @@ sub ParseFunctionSync($$$)
$res .= "\treturn NT_STATUS_NOT_IMPLEMENTED;\n";
} else {
$res .= "
- struct rpc_request *req;
NTSTATUS status;
-
- req = dcerpc_$name\_send(p, mem_ctx, r);
- if (req == NULL) return NT_STATUS_NO_MEMORY;
- status = dcerpc_ndr_request_recv(req);
+ if (p->conn->flags & DCERPC_DEBUG_PRINT_IN) {
+ NDR_PRINT_IN_DEBUG($name, r);
+ }
+
+ status = dcerpc_ndr_request(p, NULL, &ndr_table_$interface->{NAME},
+ NDR_$uname, mem_ctx, r);
if (NT_STATUS_IS_OK(status) && (p->conn->flags & DCERPC_DEBUG_PRINT_OUT)) {
NDR_PRINT_OUT_DEBUG($name, r);