mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 09:25:10 +00:00
- Prevent crashes when heapPtr is NULL, also fix broken heap magic output. Thanks Mephisto!
svn path=/trunk/; revision=34256
This commit is contained in:
parent
30db39bf92
commit
fc3136e93d
1 changed files with 4 additions and 1 deletions
|
@ -335,7 +335,10 @@ static HEAP *HEAP_GetPtr(
|
|||
HEAP *heapPtr = (HEAP *)heap;
|
||||
if (!heapPtr || (heapPtr->magic != HEAP_MAGIC))
|
||||
{
|
||||
ERR("Invalid heap %p, magic:%4s!\n", heap,heapPtr->magic );
|
||||
if (heapPtr)
|
||||
ERR("Invalid heap %p, magic:%.4s!\n", heap, &heapPtr->magic );
|
||||
else
|
||||
ERR("Invalid heap %p!\n", heap );
|
||||
//KeDumpStackFrames(NULL);
|
||||
return NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue