mirror of
https://codeberg.org/Limine/Limine
synced 2026-01-26 13:14:28 +00:00
fs/file: Fix potential issue with loading very big files on 32-bit systems
This commit is contained in:
parent
4820efdf2e
commit
07ff25bd46
@ -150,7 +150,7 @@ void *freadall_mode(struct file_handle *fd, uint32_t type, bool allow_high_alloc
|
||||
goto low_ret;
|
||||
}
|
||||
void *pool = ext_mem_alloc(0x100000);
|
||||
for (size_t i = 0; i < fd->size; i += 0x100000) {
|
||||
for (uint64_t i = 0; i < fd->size; i += 0x100000) {
|
||||
size_t count;
|
||||
if (fd->size - i < 0x100000) {
|
||||
count = fd->size - i;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user