svn commit: samba r9982 - in branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal: .

tpot at samba.org tpot at samba.org
Sat Sep 3 01:50:57 GMT 2005


Author: tpot
Date: 2005-09-03 01:50:56 +0000 (Sat, 03 Sep 2005)
New Revision: 9982

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=9982

Log:
Strip prefixes off the check for noemit in the conformance info so you
can use the typedef names in the IDL rather than the autogenerated
function names.  This means you can say "NOEMIT security_descriptor"
instead of "NOEMIT dissect_security_descriptor_type" or whatever.

Modified:
   branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/NDR.pm


Changeset:
Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/NDR.pm
===================================================================
--- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/NDR.pm	2005-09-03 00:59:55 UTC (rev 9981)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/NDR.pm	2005-09-03 01:50:56 UTC (rev 9982)
@@ -117,7 +117,7 @@
 	my $valsstring = "$ifname\_$name\_vals";
 	my $dissectorname = "$ifname\_dissect\_enum\_".StripPrefixes($name);
 
-	return if (defined($conformance->{noemit}->{$dissectorname}));
+	return if (defined($conformance->{noemit}->{StripPrefixes($name)}));
 
     	foreach (@{$e->{ELEMENTS}}) {
 		if (/([^=]*)=(.*)/) {
@@ -319,7 +319,8 @@
 
 	my $hf = register_hf_field("hf_$ifname\_$pn\_$e->{NAME}", field2name($e->{NAME}), "$ifname.$pn.$e->{NAME}", type2ft($e->{TYPE}), "BASE_HEX", "NULL", 0, "");
 
-	if (defined($conformance->{noemit}->{$dissectorname})) {
+	my $eltname = StripPrefixes($pn) . ".$e->{NAME}";
+	if (defined($conformance->{noemit}->{$eltname})) {
 		return $call_code;
 	}
 
@@ -404,7 +405,7 @@
 	my ($e,$name,$ifname) = @_;
 	my $dissectorname = "$ifname\_dissect\_struct\_".StripPrefixes($name);
 
-	return if (defined($conformance->{noemit}->{$dissectorname}));
+	return if (defined($conformance->{noemit}->{StripPrefixes($name)}));
 
 	register_ett("ett_$ifname\_$name");
 
@@ -451,7 +452,8 @@
 	my ($e,$name,$ifname) = @_;
 
 	my $dissectorname = "$ifname\_dissect_".StripPrefixes($name);
-	return if (defined($conformance->{noemit}->{$dissectorname}));
+
+	return if (defined($conformance->{noemit}->{StripPrefixes($name)}));
 	
 	register_ett("ett_$ifname\_$name");
 



More information about the samba-cvs mailing list