diff options
author | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-19 23:20:09 +0000 |
---|---|---|
committer | rvargas@google.com <rvargas@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-19 23:20:09 +0000 |
commit | aa443bbd00b53fe0701de2ca18e4f5f3acf5c25c (patch) | |
tree | 69e61525cec8890ee6cd1612e841ef661f1f1587 /chrome/browser/profile_impl.cc | |
parent | a94a03acc534fa15a278f4b6ed8f3cba8a737679 (diff) | |
download | chromium_src-aa443bbd00b53fe0701de2ca18e4f5f3acf5c25c.zip chromium_src-aa443bbd00b53fe0701de2ca18e4f5f3acf5c25c.tar.gz chromium_src-aa443bbd00b53fe0701de2ca18e4f5f3acf5c25c.tar.bz2 |
Revert 56738 - Fix CheckFalseTest.CheckFails on Linux after my change to ui_test.
This makes PathService clear its cache after overriding a path.
We have many paths depending on each other, so this is necessary
to avoid inconsistencies.
TEST=ui_tests in Release mode
BUG=49838
Review URL: http://codereview.chromium.org/2805100
TBR=phajdan.jr@chromium.org
Review URL: http://codereview.chromium.org/3169031
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@56778 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/profile_impl.cc')
-rw-r--r-- | chrome/browser/profile_impl.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/chrome/browser/profile_impl.cc b/chrome/browser/profile_impl.cc index 10ef0e7..84a2b17 100644 --- a/chrome/browser/profile_impl.cc +++ b/chrome/browser/profile_impl.cc @@ -305,15 +305,17 @@ ProfileImpl::ProfileImpl(const FilePath& path) // for a spec on where cache files go. The net effect for most systems is we // use ~/.cache/chromium/ for Chromium and ~/.cache/google-chrome/ for // official builds. + if (!PathService::IsOverridden(chrome::DIR_USER_DATA)) { #if defined(GOOGLE_CHROME_BUILD) - const char kCacheDir[] = "google-chrome"; + const char kCacheDir[] = "google-chrome"; #else - const char kCacheDir[] = "chromium"; + const char kCacheDir[] = "chromium"; #endif - PathService::Get(base::DIR_USER_CACHE, &base_cache_path_); - base_cache_path_ = base_cache_path_.Append(kCacheDir); - if (!file_util::PathExists(base_cache_path_)) - file_util::CreateDirectory(base_cache_path_); + PathService::Get(base::DIR_USER_CACHE, &base_cache_path_); + base_cache_path_ = base_cache_path_.Append(kCacheDir); + if (!file_util::PathExists(base_cache_path_)) + file_util::CreateDirectory(base_cache_path_); + } #endif if (base_cache_path_.empty()) base_cache_path_ = path_; |