mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-27 23:02:20 +00:00
Bug 554466: Only EnqueuePending when there's been an rpc out-call. r=bent
This commit is contained in:
parent
ba0dff954e
commit
f6e896ba0c
@ -96,7 +96,8 @@ RPCChannel::RPCChannel(RPCListener* aListener)
|
|||||||
mOutOfTurnReplies(),
|
mOutOfTurnReplies(),
|
||||||
mDeferred(),
|
mDeferred(),
|
||||||
mRemoteStackDepthGuess(0),
|
mRemoteStackDepthGuess(0),
|
||||||
mBlockedOnParent(false)
|
mBlockedOnParent(false),
|
||||||
|
mSawRPCOutMsg(false)
|
||||||
{
|
{
|
||||||
MOZ_COUNT_CTOR(RPCChannel);
|
MOZ_COUNT_CTOR(RPCChannel);
|
||||||
|
|
||||||
@ -597,10 +598,11 @@ void
|
|||||||
RPCChannel::ExitedCxxStack()
|
RPCChannel::ExitedCxxStack()
|
||||||
{
|
{
|
||||||
Listener()->OnExitedCxxStack();
|
Listener()->OnExitedCxxStack();
|
||||||
{
|
if (mSawRPCOutMsg) {
|
||||||
MutexAutoLock lock(mMutex);
|
MutexAutoLock lock(mMutex);
|
||||||
// see long comment in OnMaybeDequeueOne()
|
// see long comment in OnMaybeDequeueOne()
|
||||||
EnqueuePendingMessages();
|
EnqueuePendingMessages();
|
||||||
|
mSawRPCOutMsg = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -242,7 +242,10 @@ protected:
|
|||||||
|
|
||||||
if (mThat.mCxxStackFrames.empty())
|
if (mThat.mCxxStackFrames.empty())
|
||||||
mThat.EnteredCxxStack();
|
mThat.EnteredCxxStack();
|
||||||
|
|
||||||
mThat.mCxxStackFrames.push_back(RPCFrame(direction, msg));
|
mThat.mCxxStackFrames.push_back(RPCFrame(direction, msg));
|
||||||
|
mThat.mSawRPCOutMsg |= (direction == OUT_MESSAGE) &&
|
||||||
|
(msg->is_rpc());
|
||||||
}
|
}
|
||||||
|
|
||||||
~CxxStackFrame() {
|
~CxxStackFrame() {
|
||||||
@ -385,7 +388,12 @@ protected:
|
|||||||
// not protected by mMutex. It is managed exclusively by the
|
// not protected by mMutex. It is managed exclusively by the
|
||||||
// helper |class CxxStackFrame|.
|
// helper |class CxxStackFrame|.
|
||||||
std::vector<RPCFrame> mCxxStackFrames;
|
std::vector<RPCFrame> mCxxStackFrames;
|
||||||
|
|
||||||
|
// Did we process an RPC out-call during this stack? Only
|
||||||
|
// meaningful in ExitedCxxStack(), from which this variable is
|
||||||
|
// reset.
|
||||||
|
bool mSawRPCOutMsg;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
//
|
//
|
||||||
|
Loading…
Reference in New Issue
Block a user