|
52 | 52 | #include "mozilla/dom/ipc/StructuredCloneData.h" |
53 | 53 | #include "mozilla/dom/DOMStringList.h" |
54 | 54 | #include "mozilla/jsipc/CrossProcessObjectWrappers.h" |
55 | | -#include "mozilla/recordreplay/ParentIPC.h" |
56 | 55 | #include "nsPrintfCString.h" |
57 | 56 | #include "nsXULAppAPI.h" |
58 | 57 | #include "nsQueryObject.h" |
@@ -594,35 +593,11 @@ class MMListenerRemover { |
594 | 593 | RefPtr<nsFrameMessageManager> mMM; |
595 | 594 | }; |
596 | 595 |
|
597 | | -// When recording or replaying, return whether a message should be received in |
598 | | -// the middleman process instead of the recording/replaying process. |
599 | | -static bool DirectMessageToMiddleman(const nsAString& aMessage) { |
600 | | - // Middleman processes run developer tools server code and need to receive |
601 | | - // debugger related messages. The session store flush message needs to be |
602 | | - // received in order to cleanly shutdown the process. |
603 | | - return (StringBeginsWith(aMessage, NS_LITERAL_STRING("debug:")) && |
604 | | - recordreplay::parent::DebuggerRunsInMiddleman()) || |
605 | | - aMessage.EqualsLiteral("SessionStore:flush"); |
606 | | -} |
607 | | - |
608 | 596 | void nsFrameMessageManager::ReceiveMessage( |
609 | 597 | nsISupports* aTarget, nsFrameLoader* aTargetFrameLoader, bool aTargetClosed, |
610 | 598 | const nsAString& aMessage, bool aIsSync, StructuredCloneData* aCloneData, |
611 | 599 | mozilla::jsipc::CpowHolder* aCpows, nsIPrincipal* aPrincipal, |
612 | 600 | nsTArray<StructuredCloneData>* aRetVal, ErrorResult& aError) { |
613 | | - // If we are recording or replaying, we will end up here in both the |
614 | | - // middleman process and the recording/replaying process. Ignore the message |
615 | | - // in one of the processes, so that it is only received in one place. |
616 | | - if (recordreplay::IsRecordingOrReplaying()) { |
617 | | - if (DirectMessageToMiddleman(aMessage)) { |
618 | | - return; |
619 | | - } |
620 | | - } else if (recordreplay::IsMiddleman()) { |
621 | | - if (!DirectMessageToMiddleman(aMessage)) { |
622 | | - return; |
623 | | - } |
624 | | - } |
625 | | - |
626 | 601 | MOZ_ASSERT(aTarget); |
627 | 602 |
|
628 | 603 | nsAutoTObserverArray<nsMessageListenerInfo, 1>* listeners = |
|
0 commit comments