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

jelmer at samba.org jelmer at samba.org
Tue Dec 13 13:14:24 GMT 2005


Author: jelmer
Date: 2005-12-13 13:14:23 +0000 (Tue, 13 Dec 2005)
New Revision: 12206

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

Log:
Fix some issues in NOEMIT

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


Changeset:
Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
===================================================================
--- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm	2005-12-13 01:56:04 UTC (rev 12205)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm	2005-12-13 13:14:23 UTC (rev 12206)
@@ -232,11 +232,10 @@
 
 sub handle_noemit($$$)
 {
-	my ($pos,$data) = @_;
-	my $type;
+	my $pos = shift;
+	my $data = shift;
+	my $type = shift;
 
-	$type = shift if ($#_ == 1);
-
 	if (defined($type)) {
 	    $data->{noemit}->{$type} = 1;
 	} else {

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-12-13 01:56:04 UTC (rev 12205)
+++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Ethereal/NDR.pm	2005-12-13 13:14:23 UTC (rev 12206)
@@ -22,6 +22,7 @@
 use Parse::Pidl::NDR qw(ContainsString GetNextLevel);
 use Parse::Pidl::Dump qw(DumpTypedef DumpFunction);
 use Parse::Pidl::Ethereal::Conformance qw(ReadConformance);
+use File::Basename;	
 
 use vars qw($VERSION);
 $VERSION = '0.01';
@@ -206,6 +207,7 @@
 		if (defined($conformance->{tfs}->{$hf_bitname})) {
 			pidl_def "   $conformance->{tfs}->{$hf_bitname}->{TRUE_STRING},";
 			pidl_def "   $conformance->{tfs}->{$hf_bitname}->{FALSE_STRING},";
+			$conformance->{tfs}->{$hf_bitname}->{USED} = 1;
 		} else {
 			pidl_def "   \"$en is SET\",";
 			pidl_def "   \"$en is NOT SET\",";
@@ -827,7 +829,6 @@
 	$res{headers} .= "#include \"packet-dcerpc-nt.h\"\n";
 	$res{headers} .= "#include \"packet-windows-common.h\"\n";
 
-	use File::Basename;	
 	my $h_basename = basename($h_filename);
 
 	$res{headers} .= "#include \"$h_basename\"\n";
@@ -1009,6 +1010,12 @@
 			print "$_->{POS}: warning: description never used\n";
 		}
 	}
+
+	foreach (values %{$conformance->{tfs}}) {
+		if (not $_->{USED}) {
+			print "$_->{POS}: warning: True/False description never used\n";
+		}
+	}
 }
 
 1;



More information about the samba-cvs mailing list