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

Unified Diff: webkit/appcache/appcache_storage_impl.cc

Issue 9419033: Move creation of BrowserContext objects that live in content to content, instead of depending on th… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Fix memory leaks in tests Created 8 years, 10 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 | « content/test/test_browser_thread.cc ('k') | webkit/fileapi/file_system_context.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/appcache/appcache_storage_impl.cc
===================================================================
--- webkit/appcache/appcache_storage_impl.cc (revision 122721)
+++ webkit/appcache/appcache_storage_impl.cc (working copy)
@@ -1221,13 +1221,14 @@
scheduled_database_tasks_.end(),
std::mem_fun(&DatabaseTask::CancelCompletion));
- if (database_) {
- db_thread_->PostTask(
- FROM_HERE,
- base::Bind(&CleanUpOnDatabaseThread, database_,
- make_scoped_refptr(service_->special_storage_policy()),
- service()->clear_local_state_on_exit(),
- service()->save_session_state()));
+ if (database_ &&
+ !db_thread_->PostTask(
+ FROM_HERE,
+ base::Bind(&CleanUpOnDatabaseThread, database_,
+ make_scoped_refptr(service_->special_storage_policy()),
+ service()->clear_local_state_on_exit(),
+ service()->save_session_state()))) {
+ delete database_;
}
}
« no previous file with comments | « content/test/test_browser_thread.cc ('k') | webkit/fileapi/file_system_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698