summaryrefslogtreecommitdiff
path: root/source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2006-05-16 22:25:13 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:08:03 -0500
commit76aa75abc6dde74d1d8d382fe8d1fa07750a90da (patch)
treeaecfe05feeea187722c78d16d0633a39f2576d01 /source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
parent392e4b383c35ba9befd396a99f6f27608efb9862 (diff)
downloadsamba-76aa75abc6dde74d1d8d382fe8d1fa07750a90da.tar.gz
samba-76aa75abc6dde74d1d8d382fe8d1fa07750a90da.tar.bz2
samba-76aa75abc6dde74d1d8d382fe8d1fa07750a90da.zip
r15651: Add 'MANUAL' command in Ethereal conformance files. This allows overriding
individual functions for specific element levels without losing the other functions for an element or the hf/ett fields allocated. Fixes #3738. (This used to be commit a3dbab619bf8fdef002b8e31956e99226bc20e94)
Diffstat (limited to 'source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm')
-rw-r--r--source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm19
1 files changed, 16 insertions, 3 deletions
diff --git a/source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm b/source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
index e3296c1629..02319a0aa9 100644
--- a/source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
+++ b/source4/pidl/lib/Parse/Pidl/Ethereal/Conformance.pm
@@ -74,6 +74,13 @@ Code to insert when generating the specified dissector. @HF@ and
Override the text shown when a bitmap boolean value is enabled or disabled.
+=item I<MANUAL> fn_name
+
+Force pidl to not generate a particular function but allow the user
+to write a function manually. This can be used to remove the function
+for only one level for a particular element rather then all the functions and
+ett/hf variables for a particular element as the NOEMIT command does.
+
=back
=head1 EXAMPLE
@@ -232,9 +239,7 @@ sub handle_strip_prefix($$$)
sub handle_noemit($$$)
{
- my $pos = shift;
- my $data = shift;
- my $type = shift;
+ my ($pos,$data,$type) = @_;
if (defined($type)) {
$data->{noemit}->{$type} = 1;
@@ -243,6 +248,13 @@ sub handle_noemit($$$)
}
}
+sub handle_manual($$$)
+{
+ my ($pos,$data,$fn) = @_;
+
+ $data->{manual}->{$fn} = 1;
+}
+
sub handle_protocol($$$$$$)
{
my ($pos, $data, $name, $longname, $shortname, $filtername) = @_;
@@ -287,6 +299,7 @@ sub handle_import
my %field_handlers = (
TYPE => \&handle_type,
NOEMIT => \&handle_noemit,
+ MANUAL => \&handle_manual,
PARAM_VALUE => \&handle_param_value,
HF_FIELD => \&handle_hf_field,
HF_RENAME => \&handle_hf_rename,