mktables: Tighten regex match to real data
authorKarl Williamson <public@khwilliamson.com>
Sun, 20 Oct 2013 16:13:39 +0000 (10:13 -0600)
committerKarl Williamson <public@khwilliamson.com>
Tue, 31 Dec 2013 15:27:15 +0000 (08:27 -0700)
The actual file has spaces, so use \s instead of the more dangerous dot.
Also, after processing the line, no need to look to see if it matches
something else.

lib/unicore/mktables

index b806721..959bfa6 100644 (file)
@@ -17832,8 +17832,9 @@ else {
         for my $list ( \@input, \@mktables_list_output_files ) {
             while (<$file_handle>) {
                 s/^ \s+ | \s+ $//xg;
-                if (/^ \s* \# .* Autogenerated\ starting\ on\ (\d+)/x) {
+                if (/^ \s* \# \s* Autogenerated\ starting\ on\ (\d+)/x) {
                     $old_start_time = $1;
+                    next;
                 }
                 next if /^ \s* (?: \# .* )? $/x;
                 last if /^ =+ $/x;