summaryrefslogtreecommitdiffstats
path: root/base/path_service.cc
diff options
context:
space:
mode:
Diffstat (limited to 'base/path_service.cc')
-rw-r--r--base/path_service.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/base/path_service.cc b/base/path_service.cc
index 0c3c3e2..40866d1 100644
--- a/base/path_service.cc
+++ b/base/path_service.cc
@@ -219,10 +219,11 @@ bool PathService::Override(int key, const std::wstring& path) {
if (!file_util::CreateDirectory(file_path))
return false;
- file_util::TrimTrailingSeparator(&file_path);
+ FilePath fp_path = FilePath::FromWStringHack(file_path);
+ fp_path = fp_path.StripTrailingSeparators();
AutoLock scoped_lock(path_data->lock);
- path_data->cache[key] = FilePath::FromWStringHack(file_path);
+ path_data->cache[key] = fp_path;
path_data->overrides.insert(key);
return true;
}