Index: Source/WebCore/inspector/InspectorController.cpp |
=================================================================== |
--- Source/WebCore/inspector/InspectorController.cpp (revision 87486) |
+++ Source/WebCore/inspector/InspectorController.cpp (working copy) |
@@ -112,7 +112,7 @@ |
InspectorInstrumentation::frontendCreated(); |
ASSERT(m_inspectorClient); |
- m_inspectorBackendDispatcher = new InspectorBackendDispatcher( |
+ m_inspectorBackendDispatcher = adoptRef(new InspectorBackendDispatcher( |
m_inspectorClient, |
#if ENABLE(OFFLINE_WEB_APPLICATIONS) |
m_inspectorAgent->applicationCacheAgent(), |
@@ -138,7 +138,7 @@ |
m_inspectorAgent->profilerAgent(), |
#endif |
m_inspectorAgent->runtimeAgent(), |
- m_inspectorAgent->timelineAgent()); |
+ m_inspectorAgent->timelineAgent())); |
if (m_startUserInitiatedDebuggingWhenFrontedIsConnected) { |
m_inspectorFrontend->inspector()->startUserInitiatedDebugging(); |
@@ -150,6 +150,7 @@ |
{ |
if (!m_inspectorFrontend) |
return; |
+ m_inspectorBackendDispatcher->clearFrontend(); |
m_inspectorBackendDispatcher.clear(); |
m_inspectorAgent->disconnectFrontend(); |