Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(99)

Unified Diff: third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp

Issue 1437283003: [DevTools] filter any messages from previous session in DevToolsAgentHostImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp
diff --git a/third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp b/third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp
index 13101ccf9b30788fb875fda70c98dbd5ada63037..5480497c496f1277d761f37da36375e30625b300 100644
--- a/third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp
+++ b/third_party/WebKit/Source/core/inspector/WorkerInspectorController.cpp
@@ -109,7 +109,7 @@ private:
{
}
- void sendProtocolResponse(int callId, PassRefPtr<JSONObject> message) override
+ void sendProtocolResponse(int sessionId, int callId, PassRefPtr<JSONObject> message) override
{
// Worker messages are wrapped, no need to handle callId.
m_workerGlobalScope->thread()->workerReportingProxy().postMessageToPageInspector(message->toJSONString());
@@ -212,8 +212,10 @@ void WorkerInspectorController::restoreInspectorStateFromCookie(const String& in
void WorkerInspectorController::dispatchMessageFromFrontend(const String& message)
{
InspectorTaskRunner::IgnoreInterruptsScope scope(m_inspectorTaskRunner.get());
- if (m_backendDispatcher)
- m_backendDispatcher->dispatch(message);
+ if (m_backendDispatcher) {
+ // sessionId will be overwritten by WebDevToolsAgent::sendProtocolNotifications call.
+ m_backendDispatcher->dispatch(0, message);
+ }
}
void WorkerInspectorController::dispose()

Powered by Google App Engine
This is Rietveld 408576698