Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
slyshykO committed Jun 18, 2020
1 parent 1ae3c08 commit 1541dfc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -1624,7 +1624,7 @@ static int map_file(mapped_file_t* mf, const char* path) {

if (sizeof(st.st_size) != sizeof(size_t)) {
// on 32 bit systems, check if there is an overflow
if (st.st_size > (off_t)UINT32_MAX) {
if (st.st_size > (off_t)INT32_MAX) {
fprintf(stderr, "mmap() size_t overflow for file %s\n", path);
goto on_error;
}
Expand Down

0 comments on commit 1541dfc

Please sign in to comment.