summaryrefslogtreecommitdiff
path: root/pidl/lib/Parse/Pidl/Wireshark/NDR.pm
diff options
context:
space:
mode:
authorronnie sahlberg <ronniesahlberg@gmail.com>2009-10-06 17:49:59 +1100
committerAndrew Tridgell <tridge@samba.org>2009-10-06 19:11:51 +1100
commitd26016c19854142c1e5fbb5a3bfc40e7e4b1c616 (patch)
tree8b6e6a6a312fbeb1c8ccc2989a3db26b969b0f12 /pidl/lib/Parse/Pidl/Wireshark/NDR.pm
parent33347d783aa5aaae3eb90777b06412cbb2cbeca3 (diff)
downloadsamba-d26016c19854142c1e5fbb5a3bfc40e7e4b1c616.tar.gz
samba-d26016c19854142c1e5fbb5a3bfc40e7e4b1c616.tar.bz2
samba-d26016c19854142c1e5fbb5a3bfc40e7e4b1c616.zip
PIDL fix for using external types with wireshark backend
List, Please review this patch to pidl. Basically, we need to process the wireshark conformance file BEFORE we process the idl file since this file may define external types and set the alignment for them (using the TYPE directive). Otherwise pidl will default all external types to use 4byte alignment which breaks (much more often) on NDR64 regards ronnie sahlberg From 8f86903fc353d0906bd82e72ce19c5af09beb001 Mon Sep 17 00:00:00 2001 From: Ronnie Sahlberg <ronniesahlberg@gmail.com> Date: Mon, 5 Oct 2009 15:22:43 +1100 Subject: [PATCH] In the PIDL wireshark backend, we define external types in the conformance file using the TYPE directive. If we declare external types here, we must parse this file before we process the IDL file, or else these external types will all default to 4byte padding (pidl assumes all unknown types are 4byte aligned). Make sure we read the conformance file and create these new types before we parse the idl file. Signed-off-by: Ronnie Sahlberg <ronniesahlberg@gmail.com>
Diffstat (limited to 'pidl/lib/Parse/Pidl/Wireshark/NDR.pm')
-rw-r--r--pidl/lib/Parse/Pidl/Wireshark/NDR.pm4
1 files changed, 2 insertions, 2 deletions
diff --git a/pidl/lib/Parse/Pidl/Wireshark/NDR.pm b/pidl/lib/Parse/Pidl/Wireshark/NDR.pm
index a9ad555cca..e13e14465c 100644
--- a/pidl/lib/Parse/Pidl/Wireshark/NDR.pm
+++ b/pidl/lib/Parse/Pidl/Wireshark/NDR.pm
@@ -1,5 +1,5 @@
##################################################
-# Samba4 NDR parser generator for IDL structures
+# Wireshark NDR parser generator for IDL structures
# Copyright tridge@samba.org 2000-2003
# Copyright tpot@samba.org 2001,2005
# Copyright jelmer@samba.org 2004-2007
@@ -895,7 +895,7 @@ sub Initialize($$)
sub Parse($$$$$)
{
my($self,$ndr,$idl_file,$h_filename,$cnf_file) = @_;
-
+
$self->Initialize($cnf_file);
return (undef, undef) if defined($self->{conformance}->{noemit_dissector});