summaryrefslogtreecommitdiff
path: root/source4/pidl/lib/Parse
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2008-02-01 23:09:37 +0100
committerStefan Metzmacher <metze@samba.org>2008-02-07 08:33:18 +0100
commitc713b58a00b7cb5ef34b101ba5b74c8d9ec505ba (patch)
tree3a1d2778c8251e5a7aa101d03758f2b50d33289b /source4/pidl/lib/Parse
parent1ea5b06307b6057297700ce2b65b2055994869e2 (diff)
downloadsamba-c713b58a00b7cb5ef34b101ba5b74c8d9ec505ba.tar.gz
samba-c713b58a00b7cb5ef34b101ba5b74c8d9ec505ba.tar.bz2
samba-c713b58a00b7cb5ef34b101ba5b74c8d9ec505ba.zip
pidl/NDR: fix handling of multilevel pointers in function elements
The 2nd or higher level of wire pointers needs to be marked as deferred. metze (This used to be commit d7970d70329e0d4f9de30ccfcedd03e583817fa2)
Diffstat (limited to 'source4/pidl/lib/Parse')
-rw-r--r--source4/pidl/lib/Parse/Pidl/NDR.pm8
1 files changed, 4 insertions, 4 deletions
diff --git a/source4/pidl/lib/Parse/Pidl/NDR.pm b/source4/pidl/lib/Parse/Pidl/NDR.pm
index 1106247355..86ed1a8d10 100644
--- a/source4/pidl/lib/Parse/Pidl/NDR.pm
+++ b/source4/pidl/lib/Parse/Pidl/NDR.pm
@@ -173,9 +173,9 @@ sub GetElementLevelTable($$)
#
# --metze
#
- if ($i == 1) {
- $pt = pointer_type($e);
- } else {
+ $pt = pointer_type($e);
+ if ($i > 1) {
+ $is_deferred = 1 if ($pt ne "ref" and $e->{PARENT}->{TYPE} eq "FUNCTION");
$pt = $pointer_default;
}
@@ -195,7 +195,7 @@ sub GetElementLevelTable($$)
$pointer_idx++;
# everything that follows will be deferred
- $is_deferred = 1 if ($e->{PARENT}->{TYPE} ne "FUNCTION");
+ $is_deferred = 1 if ($level ne "TOP");
my $array_size = shift @size_is;
my $array_length;