riched20: Avoid invalid memory access.
This commit is contained in:
parent
e777e9d1ba
commit
7d06f6ccb2
|
@ -492,8 +492,11 @@ static ULONG WINAPI ITextRange_fnRelease(ITextRange *me)
|
|||
TRACE ("%p ref=%u\n", This, ref);
|
||||
if (ref == 0)
|
||||
{
|
||||
This->reOle = NULL;
|
||||
if (This->reOle)
|
||||
{
|
||||
list_remove(&This->entry);
|
||||
This->reOle = NULL;
|
||||
}
|
||||
heap_free(This);
|
||||
}
|
||||
return ref;
|
||||
|
|
Loading…
Reference in New Issue