mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 19:35:51 +00:00
Bug 1240985 - Stop returning MsgNotAllowed (r=dvander)
This commit is contained in:
parent
004730c364
commit
43897699b1
@ -1433,22 +1433,7 @@ MessageChannel::DispatchSyncMessage(const Message& aMsg, Message*& aReply)
|
||||
MessageChannel*& blockingVar = ShouldBlockScripts() ? gParentProcessBlocker : dummy;
|
||||
|
||||
Result rv;
|
||||
if (mTimedOutMessageSeqno && mTimedOutMessagePriority >= prio) {
|
||||
// If the other side sends a message in response to one of our messages
|
||||
// that we've timed out, then we reply with an error.
|
||||
//
|
||||
// We do this because want to avoid a situation where we process an
|
||||
// incoming message from the child here while it simultaneously starts
|
||||
// processing our timed-out CPOW. It's very bad for both sides to
|
||||
// be processing sync messages concurrently.
|
||||
//
|
||||
// The only exception is if the incoming message has urgent priority and
|
||||
// our timed-out message had only high priority. In that case it's safe
|
||||
// to process the incoming message because we know that the child won't
|
||||
// process anything (the child will defer incoming messages when waiting
|
||||
// for a response to its urgent message).
|
||||
rv = MsgNotAllowed;
|
||||
} else {
|
||||
{
|
||||
AutoSetValue<MessageChannel*> blocked(blockingVar, this);
|
||||
AutoSetValue<bool> sync(mDispatchingSyncMessage, true);
|
||||
AutoSetValue<int> prioSet(mDispatchingSyncMessagePriority, prio);
|
||||
|
Loading…
Reference in New Issue
Block a user