pidl:NDR/Client: skip all functions if pipe elements are used
authorStefan Metzmacher <metze@samba.org>
Mon, 11 Oct 2010 06:03:18 +0000 (08:03 +0200)
committerStefan Metzmacher <metze@samba.org>
Thu, 10 Mar 2011 13:31:18 +0000 (14:31 +0100)
We don't support pipe at the dcerpc level yet.

metze

pidl/lib/Parse/Pidl/Samba4/NDR/Client.pm

index 82dcc1dbec66fc9e91769d88f03bbba809790907..8f43702ad57bf70810536e4156fa0080f8122b84 100644 (file)
@@ -723,6 +723,24 @@ sub ParseFunction($$$)
 {
        my ($self, $if, $fn) = @_;
 
+       if ($self->ParseFunctionHasPipes($fn)) {
+               $self->pidl_both("/*");
+               $self->pidl_both(" * The following function is skipped because");
+               $self->pidl_both(" * it uses pipes:");
+               $self->pidl_both(" *");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}_r_send()");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}_r_recv()");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}_r()");
+               $self->pidl_both(" *");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}_send()");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}_recv()");
+               $self->pidl_both(" * dcerpc_$fn->{NAME}()");
+               $self->pidl_both(" */");
+               $self->pidl_both("");
+               warning($fn, "$fn->{NAME}: dcerpc client does not support pipe yet");
+               return;
+       }
+
        $self->ParseFunction_r_State($if, $fn, $fn->{NAME});
        $self->ParseFunction_r_Send($if, $fn, $fn->{NAME});
        $self->ParseFunction_r_Done($if, $fn, $fn->{NAME});