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

Unified Diff: content/browser/appcache/chrome_appcache_service.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/browser/appcache/chrome_appcache_service.h ('k') | content/browser/browser_context.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/appcache/chrome_appcache_service.cc
===================================================================
--- content/browser/appcache/chrome_appcache_service.cc (revision 122721)
+++ content/browser/appcache/chrome_appcache_service.cc (working copy)
@@ -45,6 +45,15 @@
ChromeAppCacheService::~ChromeAppCacheService() {
}
+void ChromeAppCacheService::DeleteOnCorrectThread() const {
+ if (BrowserThread::IsMessageLoopValid(BrowserThread::IO) &&
+ !BrowserThread::CurrentlyOn(BrowserThread::IO)) {
+ BrowserThread::DeleteSoon(BrowserThread::IO, FROM_HERE, this);
+ return;
+ }
+ delete this;
+}
+
bool ChromeAppCacheService::CanLoadAppCache(const GURL& manifest_url,
const GURL& first_party) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
« no previous file with comments | « content/browser/appcache/chrome_appcache_service.h ('k') | content/browser/browser_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698