1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 09:24:57 +00:00

cksum: Print argv[0] on failed read

Forgot to do it in c5df5e5.
This commit is contained in:
LuK1337 2021-08-01 13:04:14 +02:00 committed by Ali Mohammad Pur
parent eb6cf00c0e
commit feacf774fb

View file

@ -59,7 +59,7 @@ int main(int argc, char** argv)
while (!file->eof() && !file->has_error())
crc32.update(file->read(PAGE_SIZE));
if (file->has_error()) {
warnln("Failed to read {}: {}", filepath, file->error_string());
warnln("{}: Failed to read {}: {}", argv[0], filepath, file->error_string());
fail = true;
continue;
}
@ -69,7 +69,7 @@ int main(int argc, char** argv)
while (!file->eof() && !file->has_error())
adler32.update(file->read(PAGE_SIZE));
if (file->has_error()) {
warnln("Failed to read {}: {}", filepath, file->error_string());
warnln("{}: Failed to read {}: {}", argv[0], filepath, file->error_string());
fail = true;
continue;
}