bin/xbps-fetch: fix unreachable fetch result code

This commit restores the formerly unreachable code path handling the
case where the local file is identical with the remote file.

Fixes bug introduced in 66f84a8b59
This commit is contained in:
oopsbagel
2022-03-06 11:39:14 -08:00
committed by Duncan Overbruck
parent c08542ccac
commit 0158000c03

View File

@@ -166,7 +166,7 @@ main(int argc, char **argv)
progname, argv[i], xbps_fetch_error_string());
failure = true;
continue;
} else if (rv == -1) {
} else if (rv == 0) {
fprintf(stderr, "%s: file is identical with remote.\n", argv[i]);
if (shasum) {
if (!xbps_file_sha256_raw(digest, sizeof digest, filename)) {