Fixes a huge leak with the Inspector where it was protecting
authortimothy@apple.com <timothy@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 25 May 2008 04:47:46 +0000 (04:47 +0000)
committertimothy@apple.com <timothy@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 25 May 2008 04:47:46 +0000 (04:47 +0000)
commitbd5e0521b23c500fc7deb638d9862a3bc79bfab3
treee829a54c64c0ea66eadc62e9ad46175fd01313b6
parent5efff300b1f6f48d4b140059064b3f8a1e5a7c52
Fixes a huge leak with the Inspector where it was protecting
a large object that was not being unprotected.

<rdar://problem/5961999> Inspector protects a large JavaScript
object and never unprotects it (large leak)

Reviewed by Darin Adler.

* page/InspectorController.cpp:
(WebCore::InspectorController::inspectedPageDestroyed): Call close()
and removed a call to stopDebugging() and moved it to close().
(WebCore::InspectorController::close): Add stopDebugging() and
stopUserInitiatedProfiling(). Removed an ASSERT and added an
if statement before calling JSValueUnprotect. We don't always have
a m_scriptContext and m_scriptObject.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@34115 268f45cc-cd09-0410-ab3c-d52691b4dbfc
WebCore/ChangeLog
WebCore/page/InspectorController.cpp