summaryrefslogtreecommitdiff
path: root/pidl/lib
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2010-10-11 07:54:59 +0200
committerStefan Metzmacher <metze@samba.org>2011-03-10 14:31:17 +0100
commit7537f9c9bb78992850a641973a8df818d2fcaf25 (patch)
tree8c57301465f9cbd0b27f653ba3997fe5d013380f /pidl/lib
parent29bd658634e9afe0037170a2f3ad2512f9106761 (diff)
downloadsamba-7537f9c9bb78992850a641973a8df818d2fcaf25.tar.gz
samba-7537f9c9bb78992850a641973a8df818d2fcaf25.tar.bz2
samba-7537f9c9bb78992850a641973a8df818d2fcaf25.zip
pidl:Python: don't generate functions with pipe elements
metze
Diffstat (limited to 'pidl/lib')
-rw-r--r--pidl/lib/Parse/Pidl/Samba4/Python.pm11
1 files changed, 10 insertions, 1 deletions
diff --git a/pidl/lib/Parse/Pidl/Samba4/Python.pm b/pidl/lib/Parse/Pidl/Samba4/Python.pm
index dfacfb3352..db2d79d2f6 100644
--- a/pidl/lib/Parse/Pidl/Samba4/Python.pm
+++ b/pidl/lib/Parse/Pidl/Samba4/Python.pm
@@ -12,7 +12,7 @@ use strict;
use Parse::Pidl qw(warning fatal error);
use Parse::Pidl::Typelist qw(hasType resolveType getType mapTypeName expandAlias);
use Parse::Pidl::Util qw(has_property ParseExpr unmake_str);
-use Parse::Pidl::NDR qw(GetPrevLevel GetNextLevel ContainsDeferred is_charset_array);
+use Parse::Pidl::NDR qw(GetPrevLevel GetNextLevel ContainsDeferred ContainsPipe is_charset_array);
use Parse::Pidl::CUtil qw(get_value_of get_pointer_to);
use Parse::Pidl::Samba4 qw(ArrayDynamicallyAllocated);
use Parse::Pidl::Samba4::Header qw(GenerateFunctionInEnv GenerateFunctionOutEnv EnvSubstituteValue GenerateStructEnv);
@@ -667,6 +667,15 @@ sub Interface($$$)
next if has_property($d, "nopython");
next if has_property($d, "todo");
+ my $skip = 0;
+ foreach my $e (@{$d->{ELEMENTS}}) {
+ if (ContainsPipe($e, $e->{LEVELS}[0])) {
+ $skip = 1;
+ last;
+ }
+ }
+ next if $skip;
+
my $prettyname = $d->{NAME};
$prettyname =~ s/^$interface->{NAME}_//;