bug 1187055 - check the proxy being destroyed has a wrapper before cleaning it up r=davidb

All proxies should have wrappers on windows.  So it doesn't make much sense
that we need a null check here, however it seems to happen in the wild that
proxy->GetWrapper() returns null.
This commit is contained in:
Trevor Saunders 2015-07-27 17:52:03 -04:00
parent b5310ade5f
commit 0e0d0d9ae0

View File

@ -49,6 +49,10 @@ a11y::ProxyDestroyed(ProxyAccessible* aProxy)
{
ProxyAccessibleWrap* wrapper =
reinterpret_cast<ProxyAccessibleWrap*>(aProxy->GetWrapper());
MOZ_ASSERT(wrapper);
if (!wrapper)
return;
wrapper->Shutdown();
aProxy->SetWrapper(0);
wrapper->Release();