summaryrefslogtreecommitdiffstats
path: root/pidl
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2013-09-26 01:20:10 +0200
committerStefan Metzmacher <metze@samba.org>2014-01-07 08:37:37 +0100
commitf50b561336c7b6c08300e6e477859d1f9fab62c2 (patch)
tree47779c9974d01ce732828cd11e2a000f493b8cb8 /pidl
parent662fc2de8c2896503026a2a4052ed1ea8ce78af5 (diff)
downloadsamba-f50b561336c7b6c08300e6e477859d1f9fab62c2.tar.gz
samba-f50b561336c7b6c08300e6e477859d1f9fab62c2.tar.xz
samba-f50b561336c7b6c08300e6e477859d1f9fab62c2.zip
pidl:NDR/Client: fix dcerpc_function() with [out,ref] pointers
Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
Diffstat (limited to 'pidl')
-rw-r--r--pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm14
1 files changed, 14 insertions, 0 deletions
diff --git a/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm b/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
index 06cc65a2a61..f02b8b20251 100644
--- a/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm
@@ -692,6 +692,20 @@ sub ParseFunction_Sync($$$$)
}
$self->pidl("");
+ $self->pidl("/* Out parameters */");
+ foreach my $e (@{$fn->{ELEMENTS}}) {
+ next unless grep(/out/, @{$e->{DIRECTION}});
+
+ $self->ParseCopyArgument($fn, $e, "r.out.", "_");
+ }
+ $self->pidl("");
+
+ if (defined($fn->{RETURN_TYPE})) {
+ $self->pidl("/* Result */");
+ $self->pidl("ZERO_STRUCT(r.out.result);");
+ $self->pidl("");
+ }
+
$self->pidl("status = dcerpc_$name\_r(h, mem_ctx, &r);");
$self->pidl("if (!NT_STATUS_IS_OK(status)) {");
$self->indent;