Build correct base table in init.lua after changes in epan/proto.h

svn path=/trunk/; revision=54293
This commit is contained in:
Stig Bjørlykke 2013-12-20 13:38:36 +00:00
parent db3c476e6c
commit de2bcb2c8e
1 changed files with 2 additions and 5 deletions

View File

@ -118,13 +118,10 @@ $bases_table = "-- Display Bases\n base = {\n";
$encodings = "-- Encodings\n";
$expert_pi = "-- Expert flags and facilities\n";
my $base_num = 0;
open PROTO_H, "< $WSROOT/epan/proto.h" or die "cannot open '$WSROOT/epan/proto.h': $!";
while(<PROTO_H>) {
if (/^\s+BASE_([A-Z_]+),/ ) {
$bases_table .= "\t[\"$1\"] = $base_num,\n";
$base_num++;
if (/^\s+BASE_([A-Z_]+)[ ]*=[ ]*([0-9]+),/ ) {
$bases_table .= "\t[\"$1\"] = $2,\n";
}
if ( /^.define\s+(PI_[A-Z_]+)\s+((0x)?[0-9A-Fa-f]+)/ ) {