From: Andrew Gildfind Date: Thu, 26 Apr 2001 23:48:06 +0000 (+0000) Subject: when checking filesystem don't stop for missing/corrupt file just print a message X-Git-Tag: v1.1.0~1267 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=c5d447557d83969c3e56c55e784ba14eea522c9a;p=users%2Fhch%2Fxfstests-dev.git when checking filesystem don't stop for missing/corrupt file just print a message and keep checking. --- diff --git a/src/fill2fs_check b/src/fill2fs_check index 2c96e5d51..2dbe6ff4c 100755 --- a/src/fill2fs_check +++ b/src/fill2fs_check @@ -39,22 +39,26 @@ # Read a manifest generated by fill2fs from the command # line or stdin, checksum every file listed # -# $Id$ +# $Id: fill2fs_check,v 1.1 2001/04/26 23:46:25 ajag Exp ajag $ # use File::Basename; -while (<>) { +$status = 0; + +file: while (<>) { chomp; if ( ! -e $_) { print "$0: $_ not found\n"; - exit(1); + $status = 1; next file; } (undef, $expected) = split(/\./, basename $_); chomp($sum = `sum -r $_`); ($actual) = split(/\s+/, $sum); if ($actual != $expected) { print "$0: checksum is wrong for \"$_\"\n"; - exit(1); + $status = 1; next file; } } + +exit($status);