summaryrefslogtreecommitdiff
path: root/source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2005-10-04 19:38:35 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:39:24 -0500
commit9879bc6aa6c7997220079b3501b9a4fb3682c813 (patch)
treea447269ee5ecdbbfe9e62a04bf724e4bba896355 /source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm
parenteea74cde05c1532d59b9f8ecc4f88c191a4b200f (diff)
downloadsamba-9879bc6aa6c7997220079b3501b9a4fb3682c813.tar.gz
samba-9879bc6aa6c7997220079b3501b9a4fb3682c813.tar.bz2
samba-9879bc6aa6c7997220079b3501b9a4fb3682c813.zip
r10717: Another bunch of small updates. All generated files except parse_dfs.c
compile now when generated from Samba4's dfs.idl. (This used to be commit 2b315b1942e77640eca8e0a3347b2a9ed1920f6a)
Diffstat (limited to 'source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm')
-rw-r--r--source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm20
1 files changed, 13 insertions, 7 deletions
diff --git a/source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm b/source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm
index 57ee1543ff..9a7c7d2578 100644
--- a/source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm
+++ b/source4/pidl/lib/Parse/Pidl/Samba3/Parser.pm
@@ -143,9 +143,9 @@ sub InitLevel($$$$)
}
}
-sub CreateStruct($$$$)
+sub CreateStruct($$$$$)
{
- my ($fn,$s,$es,$a) = @_;
+ my ($fn,$ifn, $s,$es,$a) = @_;
my $args = "";
foreach (@$es) {
@@ -167,10 +167,10 @@ sub CreateStruct($$$$)
}
}
- pidl "BOOL init_$fn($s *v$args)";
+ pidl "BOOL $ifn($s *v$args)";
pidl "{";
indent;
- pidl "DEBUG(5,(\"init_$fn\\n\"));";
+ pidl "DEBUG(5,(\"$ifn\\n\"));";
pidl "";
# Call init for all arguments
foreach (@$es) {
@@ -215,7 +215,7 @@ sub ParseStruct($$$)
my $fn = "$if->{NAME}_io_$n";
my $sn = uc("$if->{NAME}_$n");
- CreateStruct($fn, $sn, $s->{ELEMENTS}, $s->{ALIGN});
+ CreateStruct($fn, "init_$if->{NAME}_$n", $sn, $s->{ELEMENTS}, $s->{ALIGN});
}
sub ParseUnion($$$)
@@ -282,8 +282,14 @@ sub ParseFunction($$)
} );
}
- CreateStruct("$if->{NAME}_io_q_$fn->{NAME}", uc("$if->{NAME}_q_$fn->{NAME}"), \@in, 0);
- CreateStruct("$if->{NAME}_io_r_$fn->{NAME}", uc("$if->{NAME}_r_$fn->{NAME}"), \@out, 0);
+ CreateStruct("$if->{NAME}_io_q_$fn->{NAME}",
+ "init_$if->{NAME}_q_$fn->{NAME}",
+ uc("$if->{NAME}_q_$fn->{NAME}"),
+ \@in, 0);
+ CreateStruct("$if->{NAME}_io_r_$fn->{NAME}",
+ "init_$if->{NAME}_r_$fn->{NAME}",
+ uc("$if->{NAME}_r_$fn->{NAME}"),
+ \@out, 0);
}
sub ParseInterface($)