зеркало из https://github.com/mozilla/gecko-dev.git
Bug 996508 - Don't deliver async messages which were already received. r=smaug
This commit is contained in:
Родитель
d975eff099
Коммит
8fc086c1a7
|
@ -1774,6 +1774,7 @@ public:
|
|||
JS::Handle<JSObject *> aCpows,
|
||||
nsIPrincipal* aPrincipal)
|
||||
: nsSameProcessAsyncMessageBase(aCx, aMessage, aData, aCpows, aPrincipal)
|
||||
, mDelivered(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -1782,10 +1783,16 @@ public:
|
|||
if (nsFrameMessageManager::sPendingSameProcessAsyncMessages) {
|
||||
nsFrameMessageManager::sPendingSameProcessAsyncMessages->RemoveElement(this);
|
||||
}
|
||||
if (!mDelivered) {
|
||||
mDelivered = true;
|
||||
nsFrameMessageManager* ppm = nsFrameMessageManager::sSameProcessParentManager;
|
||||
ReceiveMessage(static_cast<nsIContentFrameMessageManager*>(ppm), ppm);
|
||||
}
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
private:
|
||||
bool mDelivered;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
Загрузка…
Ссылка в новой задаче