Move more file_util functions to base namespace.
TBR=jam
Review URL: https://codereview.chromium.org/189333004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@256863 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/base/file_util.cc b/base/file_util.cc
index 87b9afb99..c1bf50a 100644
--- a/base/file_util.cc
+++ b/base/file_util.cc
@@ -236,18 +236,8 @@
return true;
}
-} // namespace base
-
-// -----------------------------------------------------------------------------
-
-namespace file_util {
-
-using base::FilePath;
-using base::kMaxUniqueFiles;
-
-int GetUniquePathNumber(
- const FilePath& path,
- const FilePath::StringType& suffix) {
+int GetUniquePathNumber(const FilePath& path,
+ const FilePath::StringType& suffix) {
bool have_suffix = !suffix.empty();
if (!PathExists(path) &&
(!have_suffix || !PathExists(FilePath(path.value() + suffix)))) {
@@ -256,8 +246,7 @@
FilePath new_path;
for (int count = 1; count <= kMaxUniqueFiles; ++count) {
- new_path =
- path.InsertBeforeExtensionASCII(base::StringPrintf(" (%d)", count));
+ new_path = path.InsertBeforeExtensionASCII(StringPrintf(" (%d)", count));
if (!PathExists(new_path) &&
(!have_suffix || !PathExists(FilePath(new_path.value() + suffix)))) {
return count;
@@ -267,4 +256,4 @@
return -1;
}
-} // namespace file_util
+} // namespace base