diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2024-03-27 15:01:16 +0100 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2024-03-27 15:01:16 +0100 |
| commit | e1f69b9c6171f5d2a67017194232a77025a4a096 (patch) | |
| tree | 652e533d98d5331f68f643e64caa5cb03e6baa71 /src/elfs | |
| parent | 81f25b219ff69171f2fac2263ce7d49e8b7456b0 (diff) | |
| download | box64-e1f69b9c6171f5d2a67017194232a77025a4a096.tar.gz box64-e1f69b9c6171f5d2a67017194232a77025a4a096.zip | |
Improve memory handling for wine, again
Diffstat (limited to 'src/elfs')
| -rw-r--r-- | src/elfs/elfloader.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/elfs/elfloader.c b/src/elfs/elfloader.c index 441595e0..29a247c6 100644 --- a/src/elfs/elfloader.c +++ b/src/elfs/elfloader.c @@ -385,8 +385,10 @@ void FreeElfMemory(elfheader_t* head) box_free(head->multiblocks); } // we only need to free the overall mmap, no need to free individual part as they are inside the big one - if(head->raw && head->raw_size) + if(head->raw && head->raw_size) { + dynarec_log(LOG_INFO, "Unmap elf memory %p-%p for %s\n", head->raw, head->raw+head->raw_size, head->path); munmap(head->raw, head->raw_size); + } freeProtection((uintptr_t)head->raw, head->raw_size); } |