Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit 49f8d5f

Browse files
committed
Do not verify size field in BMP files as it is redundant and usually wrong
1 parent 22ffacd commit 49f8d5f

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

source/deps/illa/bmp_fileheader.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,6 @@ namespace Img {
1818
if (type != BITMAP_SIGN) {
1919
DO_THROW(Err::InvalidHeader, TX("Magic bytes didn't match."));
2020
}
21-
22-
if (size > file->Size()) {
23-
DO_THROW(Err::InvalidHeader, TX("File seems to be truncated."));
24-
}
2521
}
2622

2723
BMPFileHeader::BMPFileHeader() {}

0 commit comments

Comments
 (0)