]> git.donarmstrong.com Git - bugscan.git/blobdiff - scanlib.pm
readstatus supports empty status files
[bugscan.git] / scanlib.pm
index 6ed7cce85390860ab9661beaa7d67e79dad155ad..a728bd0c2a9c4b6f5a9b0d9855f61f74dc7c1aa2 100644 (file)
@@ -258,7 +258,9 @@ sub readstatus {
                or die "$filename: $!";
 
     while (1) {
-               chomp (my $type = <STATUS>);
+               my $type = <STATUS>;
+        last if not defined $type;
+        chomp $type;
                if ($type eq 'package') {
                        chomp (my $package = <STATUS>);
                        chomp (my $section = <STATUS>);