diff options
author | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-27 00:04:24 +0000 |
---|---|---|
committer | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-27 00:04:24 +0000 |
commit | 9fde2a2f20e1cbd68d88ae5769bb8018b9b4422e (patch) | |
tree | a1a7c0a71e057b93275dd29f390cafa3d9dff630 /net/disk_cache/backend_impl.cc | |
parent | efc7057308ae81e69861d37aaca33b67d5187284 (diff) | |
download | chromium_src-9fde2a2f20e1cbd68d88ae5769bb8018b9b4422e.zip chromium_src-9fde2a2f20e1cbd68d88ae5769bb8018b9b4422e.tar.gz chromium_src-9fde2a2f20e1cbd68d88ae5769bb8018b9b4422e.tar.bz2 |
Implement sync IO for the disk cache, and temporarily redirect
async IO to be performed synchronously.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1414 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/disk_cache/backend_impl.cc')
-rw-r--r-- | net/disk_cache/backend_impl.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/net/disk_cache/backend_impl.cc b/net/disk_cache/backend_impl.cc index 943e355..18025a1 100644 --- a/net/disk_cache/backend_impl.cc +++ b/net/disk_cache/backend_impl.cc @@ -123,7 +123,12 @@ bool DelayedCacheCleanup(const std::wstring& full_path) { return false; } +#if defined(OS_WIN) WorkerPool::PostTask(FROM_HERE, new CleanupTask(path, name), true); +#elif defined(OS_POSIX) + // TODO(rvargas): Use the worker pool. + MessageLoop::current()->PostTask(FROM_HERE, new CleanupTask(path, name)); +#endif return true; } @@ -757,7 +762,7 @@ bool BackendImpl::InitBackingStore(bool* file_created) { bool ret = true; if (*file_created) ret = CreateBackingStore(file); - + file = NULL; if (!ret) return false; |