* Fix memory leak in win32 VM code (arQon/dmitry)

This commit is contained in:
Tim Angus 2008-08-06 16:09:29 +00:00
parent 1b87aff448
commit 9a5d971705
2 changed files with 2 additions and 2 deletions

View file

@ -1123,7 +1123,7 @@ void VM_Destroy_Compiled(vm_t* self)
#ifdef VM_X86_MMAP
munmap(self->codeBase, self->codeLength);
#elif _WIN32
VirtualFree(self->codeBase, self->codeLength, MEM_RELEASE);
VirtualFree(self->codeBase, 0, MEM_RELEASE);
#else
free(self->codeBase);
#endif

View file

@ -1040,7 +1040,7 @@ void VM_Destroy_Compiled(vm_t* self)
#ifdef USE_GAS
munmap(self->codeBase, self->codeLength);
#elif _WIN32
VirtualFree(self->codeBase, self->codeLength, MEM_RELEASE);
VirtualFree(self->codeBase, 0, MEM_RELEASE);
#else
munmap(self->codeBase, self->codeLength);
#endif