summaryrefslogtreecommitdiffstats
path: root/base/file_util.h
diff options
context:
space:
mode:
authorbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-30 18:23:50 +0000
committerbrettw@chromium.org <brettw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-08-30 18:23:50 +0000
commit82f84b91a10f513cd59b8382a7ab00ed0f179bd5 (patch)
tree125081aff715fbe6815e8bb81889d4d49f887cf3 /base/file_util.h
parent88a8115978d75161674d97cde0761cbdba73daed (diff)
downloadchromium_src-82f84b91a10f513cd59b8382a7ab00ed0f179bd5.zip
chromium_src-82f84b91a10f513cd59b8382a7ab00ed0f179bd5.tar.gz
chromium_src-82f84b91a10f513cd59b8382a7ab00ed0f179bd5.tar.bz2
Move ReadFileToString to the base namespace.
BUG= Review URL: https://codereview.chromium.org/19579005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@220612 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/file_util.h')
-rw-r--r--base/file_util.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/base/file_util.h b/base/file_util.h
index 9673a61..b4150f7 100644
--- a/base/file_util.h
+++ b/base/file_util.h
@@ -132,19 +132,18 @@ BASE_EXPORT bool ContentsEqual(const FilePath& filename1,
BASE_EXPORT bool TextContentsEqual(const FilePath& filename1,
const FilePath& filename2);
-} // namespace base
-
-// -----------------------------------------------------------------------------
-
-namespace file_util {
-
// Read the file at |path| into |contents|, returning true on success.
// This function fails if the |path| contains path traversal components ('..').
// |contents| may be NULL, in which case this function is useful for its
// side effect of priming the disk cache.
// Useful for unit tests.
-BASE_EXPORT bool ReadFileToString(const base::FilePath& path,
- std::string* contents);
+BASE_EXPORT bool ReadFileToString(const FilePath& path, std::string* contents);
+
+} // namespace base
+
+// -----------------------------------------------------------------------------
+
+namespace file_util {
#if defined(OS_POSIX)
// Read exactly |bytes| bytes from file descriptor |fd|, storing the result