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

Unified Diff: third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp

Issue 1893203004: [DevTools] Fix leak in InspectorDatabaseAgent. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months 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
« no previous file with comments | « third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp
diff --git a/third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp b/third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp
index cf8cf300c734785e4ac1f56dceed78d67b79ff6c..804de09171cb7d21735369d56c191890e3fff5fe 100644
--- a/third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp
+++ b/third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.cpp
@@ -259,6 +259,12 @@ InspectorDatabaseAgent::~InspectorDatabaseAgent()
{
}
+void InspectorDatabaseAgent::discardAgent()
+{
+ if (DatabaseClient* client = DatabaseClient::fromPage(m_page))
+ client->setInspectorAgent(nullptr);
+}
+
void InspectorDatabaseAgent::enable(ErrorString*)
{
if (m_enabled)
« no previous file with comments | « third_party/WebKit/Source/modules/webdatabase/InspectorDatabaseAgent.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698