summaryrefslogtreecommitdiff
path: root/tools/fix-encoding-args.pl
diff options
context:
space:
mode:
authorBill Meier <wmeier@newsguy.com>2011-10-24 17:36:20 +0000
committerBill Meier <wmeier@newsguy.com>2011-10-24 17:36:20 +0000
commitc1f8fb39358c8696cec0c766a906360b00023527 (patch)
treeaa3d0cbba5df8f39c16ebb88e95740e1d8d396e0 /tools/fix-encoding-args.pl
parentaf46b3f92973d11e4714ba13432e6258f186a071 (diff)
downloadwireshark-c1f8fb39358c8696cec0c766a906360b00023527.tar.gz
Fix bug (introduced in SVN #39504) which caused only 1st file of a list to be processed.
svn path=/trunk/; revision=39536
Diffstat (limited to 'tools/fix-encoding-args.pl')
-rwxr-xr-xtools/fix-encoding-args.pl8
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/fix-encoding-args.pl b/tools/fix-encoding-args.pl
index 591a4b97c0..9af88d034e 100755
--- a/tools/fix-encoding-args.pl
+++ b/tools/fix-encoding-args.pl
@@ -219,6 +219,8 @@ if (!$result || $helpFlag || !$ARGV[0]) {
# Note: The proto_tree_add_item() encoding arg will be converted only if
# the hf_index_name referenced is in one of the entries in hf[] in the same file
+my $found_total = 0;
+
while (my $fileName = $ARGV[0]) {
shift;
my $fileContents = '';
@@ -257,7 +259,7 @@ while (my $fileName = $ARGV[0]) {
print FCO "$fileContents";
close(FCO);
}
- exit $found;
+ $found_total += $found;
# Optional searches:
# search for (and output) proto_tree_add_item() statements with invalid encoding arg for specified field types
@@ -274,7 +276,9 @@ while (my $fileName = $ARGV[0]) {
# and output same highlighting the encoding arg
# find_all(\$fileContents, $fileName);
-}
+} # while
+
+exit $found_total;
#==================================================================================