dbghelp: nread can be NULL for read_mem and read_mem64.

This commit is contained in:
Rob Shearman 2007-02-15 16:24:39 +00:00 committed by Alexandre Julliard
parent d74712690c
commit 3f8215d214
1 changed files with 2 additions and 2 deletions

View File

@ -62,7 +62,7 @@ static BOOL CALLBACK read_mem(HANDLE hProcess, DWORD addr, void* buffer,
{
SIZE_T r;
if (!ReadProcessMemory(hProcess, (void*)addr, buffer, size, &r)) return FALSE;
*nread = r;
if (nread) *nread = r;
return TRUE;
}
@ -71,7 +71,7 @@ static BOOL CALLBACK read_mem64(HANDLE hProcess, DWORD64 addr, void* buffer,
{
SIZE_T r;
if (!ReadProcessMemory(hProcess, (void*)(DWORD_PTR)addr, buffer, size, &r)) return FALSE;
*nread = r;
if (nread) *nread = r;
return TRUE;
}