Fix exception handling

This commit is contained in:
Ryan Dortmans
2004-11-18 09:07:46 +00:00
parent 6b3e3a8c78
commit 72a7b12469
2 changed files with 6 additions and 2 deletions
@@ -297,7 +297,11 @@ bool VirtualMemoryManager::DecommitLRU()
// decommit this page
// write to the page file
if(SetFilePointer(vmemFile, addr - baseAddress, 0, FILE_BEGIN) == INVALID_SET_FILE_POINTER)
{
if(LOG)
LOG->Trace("Vmem error: could not write to page file");
return false;
}
DWORD written;
@@ -511,7 +515,7 @@ void vfree(void *ptr)
HeapFree(GetProcessHeap(), 0, ptr);
}
int CheckPageFault(LPEXCEPTION_POINTERS e)
LONG _stdcall CheckPageFault(LPEXCEPTION_POINTERS e)
{
if(LOG && e->ExceptionRecord->ExceptionCode != EXCEPTION_ACCESS_VIOLATION)
LOG->Trace("Exception: %u", e->ExceptionRecord->ExceptionCode);
+1 -1
View File
@@ -59,7 +59,7 @@ void vfree(void *ptr);
extern VirtualMemoryManager vmem_Manager;
int CheckPageFault(LPEXCEPTION_POINTERS e);
LONG _stdcall CheckPageFault(LPEXCEPTION_POINTERS e);
int NoMemory(size_t size);
#endif