summaryrefslogtreecommitdiffstats
path: root/base/file_util.cc
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-09 15:39:48 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-07-09 15:39:48 +0000
commitb9ff9c1b2ef0abd27a642469d4bf705be58ae7f2 (patch)
treea1d97b2e680a86fac8537162b2e61b9474d8ad00 /base/file_util.cc
parent51c418ffb35b1fa51368e69f3ecad1c4039f41ab (diff)
downloadchromium_src-b9ff9c1b2ef0abd27a642469d4bf705be58ae7f2.zip
chromium_src-b9ff9c1b2ef0abd27a642469d4bf705be58ae7f2.tar.gz
chromium_src-b9ff9c1b2ef0abd27a642469d4bf705be58ae7f2.tar.bz2
file_util: Move deprecated function UpOneDirectoryOrEmpty into an anonymous namespace.
This function is used in one place and is deprecated, so would be good to move it there so no one can make other uses of it. BUG=24672 TEST=trybots Review URL: http://codereview.chromium.org/2809049 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@51963 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/file_util.cc')
-rw-r--r--base/file_util.cc10
1 files changed, 0 insertions, 10 deletions
diff --git a/base/file_util.cc b/base/file_util.cc
index bae6535..b611716 100644
--- a/base/file_util.cc
+++ b/base/file_util.cc
@@ -402,16 +402,6 @@ void UpOneDirectory(std::wstring* dir) {
if (directory.value() != FilePath::kCurrentDirectory)
*dir = directory.ToWStringHack();
}
-void UpOneDirectoryOrEmpty(std::wstring* dir) {
- FilePath path = FilePath::FromWStringHack(*dir);
- FilePath directory = path.DirName();
- // If there is no separator, we will get back kCurrentDirectory.
- // In this case, clear dir.
- if (directory == path || directory.value() == FilePath::kCurrentDirectory)
- dir->clear();
- else
- *dir = directory.ToWStringHack();
-}
int WriteFile(const std::wstring& filename, const char* data, int size) {
return WriteFile(FilePath::FromWStringHack(filename), data, size);
}