mirror of
https://github.com/reactos/reactos.git
synced 2024-09-15 07:05:04 +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
|
@ -335,7 +335,10 @@ static HEAP *HEAP_GetPtr(
|
||||||
HEAP *heapPtr = (HEAP *)heap;
|
HEAP *heapPtr = (HEAP *)heap;
|
||||||
if (!heapPtr || (heapPtr->magic != HEAP_MAGIC))
|
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);
|
//KeDumpStackFrames(NULL);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue