Skip to content

Commit c9f916e

Browse files
committed
Improve checksum error
1 parent 0e98d15 commit c9f916e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/binary/download.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func Download(bin *IndexBin) ([]byte, error) {
4040
return nil, fmt.Errorf("cannot retrieve binary size: %w", err)
4141
}
4242
if len(b) != int(sz) {
43-
return nil, errors.New("download failed: invalid binary size")
43+
return nil, fmt.Errorf("download failed: invalid binary size, expected %d bytes but got %d", sz, len(b))
4444
}
4545

4646
err = fwuploader.VerifyChecksum(bin.Checksum, bytes.NewReader(b))

0 commit comments

Comments
 (0)