Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(110)

Side by Side Diff: base/file_util.cc

Issue 11208: Implement some missing file util functions. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 12 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/file_util.h ('k') | base/file_util_linux.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/file_util.h" 5 #include "base/file_util.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include <fstream> 9 #include <fstream>
10 10
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 bool GetFileSize(const std::wstring& file_path, int64* file_size) { 363 bool GetFileSize(const std::wstring& file_path, int64* file_size) {
364 return GetFileSize(FilePath::FromWStringHack(file_path), file_size); 364 return GetFileSize(FilePath::FromWStringHack(file_path), file_size);
365 } 365 }
366 bool GetTempDir(std::wstring* path_str) { 366 bool GetTempDir(std::wstring* path_str) {
367 FilePath path; 367 FilePath path;
368 if (!GetTempDir(&path)) 368 if (!GetTempDir(&path))
369 return false; 369 return false;
370 *path_str = path.ToWStringHack(); 370 *path_str = path.ToWStringHack();
371 return true; 371 return true;
372 } 372 }
373 FILE* OpenFile(const std::wstring& filename, const char* mode) {
374 return OpenFile(FilePath::FromWStringHack(filename), mode);
375 }
376 bool SetCurrentDirectory(const std::wstring& directory) {
377 return SetCurrentDirectory(FilePath::FromWStringHack(directory));
378 }
373 379
374 } // namespace 380 } // namespace
375 381
OLDNEW
« no previous file with comments | « base/file_util.h ('k') | base/file_util_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698