projects
/
deb
/
packages.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
dfdc4f2
)
parse-contents: Fix display of progress
author
Frank Lichtenheld
<frank@lichtenheld.de>
Mon, 8 Oct 2007 01:37:54 +0000
(
03:37
+0200)
committer
Frank Lichtenheld
<frank@lichtenheld.de>
Mon, 8 Oct 2007 01:37:54 +0000
(
03:37
+0200)
Files without header did confuse the line numbers
bin/parse-contents
patch
|
blob
|
history
diff --git
a/bin/parse-contents
b/bin/parse-contents
index 414dc8ac0a623c1f11e04154423881f033478cc7..b8cc8e4158a2b7cffb1566f09d674ac7f560796d 100755
(executable)
--- a/
bin/parse-contents
+++ b/
bin/parse-contents
@@
-82,8
+82,11
@@
for my $suite (@suites) {
open CONT, "zcat $filename|$what"
or die $!;
- while (<CONT>) {last if /^FILE/mo;}
- open CONT, "zcat $filename|$what" if eof(CONT);
+ while (<CONT>) { last if /^FILE/mo; }
+ if (eof(CONT)) { # no header found
+ close CONT; # explicit close to reset $.
+ open CONT, "zcat $filename|$what";
+ }
while (<CONT>) {
my $data = "";
my %data = ();