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

Side by Side Diff: chrome/browser/first_run/upgrade_util_linux.cc

Issue 101143006: Convert base::file_util to use File instead of PlatformFile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove base:: Created 6 years, 11 months 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/browser/first_run/upgrade_util.h" 5 #include "chrome/browser/first_run/upgrade_util.h"
6 6
7 #include "base/base_paths.h" 7 #include "base/base_paths.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 22 matching lines...) Expand all
33 void SaveLastModifiedTimeOfExe() { 33 void SaveLastModifiedTimeOfExe() {
34 saved_last_modified_time_of_exe = GetLastModifiedTimeOfExe(); 34 saved_last_modified_time_of_exe = GetLastModifiedTimeOfExe();
35 } 35 }
36 36
37 double GetLastModifiedTimeOfExe() { 37 double GetLastModifiedTimeOfExe() {
38 base::FilePath exe_file_path; 38 base::FilePath exe_file_path;
39 if (!PathService::Get(base::FILE_EXE, &exe_file_path)) { 39 if (!PathService::Get(base::FILE_EXE, &exe_file_path)) {
40 LOG(WARNING) << "Failed to get base::FilePath object for FILE_EXE."; 40 LOG(WARNING) << "Failed to get base::FilePath object for FILE_EXE.";
41 return saved_last_modified_time_of_exe; 41 return saved_last_modified_time_of_exe;
42 } 42 }
43 base::PlatformFileInfo exe_file_info; 43 base::File::Info exe_file_info;
44 if (!base::GetFileInfo(exe_file_path, &exe_file_info)) { 44 if (!base::GetFileInfo(exe_file_path, &exe_file_info)) {
45 LOG(WARNING) << "Failed to get FileInfo object for FILE_EXE - " 45 LOG(WARNING) << "Failed to get FileInfo object for FILE_EXE - "
46 << exe_file_path.value(); 46 << exe_file_path.value();
47 return saved_last_modified_time_of_exe; 47 return saved_last_modified_time_of_exe;
48 } 48 }
49 return exe_file_info.last_modified.ToDoubleT(); 49 return exe_file_info.last_modified.ToDoubleT();
50 } 50 }
51 51
52 } // namespace upgrade_util 52 } // namespace upgrade_util
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698