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

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

Issue 7377012: Change base::LaunchProcess API slightly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 5 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 <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/base_paths.h" 10 #include "base/base_paths.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 return false; 57 return false;
58 } 58 }
59 59
60 } // namespace 60 } // namespace
61 61
62 namespace upgrade_util { 62 namespace upgrade_util {
63 63
64 bool RelaunchChromeBrowser(const CommandLine& command_line) { 64 bool RelaunchChromeBrowser(const CommandLine& command_line) {
65 scoped_ptr<base::Environment> env(base::Environment::Create()); 65 scoped_ptr<base::Environment> env(base::Environment::Create());
66 env->UnSetVar(chrome::kChromeVersionEnvVar); 66 env->UnSetVar(chrome::kChromeVersionEnvVar);
67 return base::LaunchProcess(command_line, base::LaunchOptions()); 67 return base::LaunchProcess(command_line, base::LaunchOptions(), NULL);
68 } 68 }
69 69
70 bool IsUpdatePendingRestart() { 70 bool IsUpdatePendingRestart() {
71 FilePath new_chrome_exe; 71 FilePath new_chrome_exe;
72 if (!GetNewerChromeFile(&new_chrome_exe)) 72 if (!GetNewerChromeFile(&new_chrome_exe))
73 return false; 73 return false;
74 return file_util::PathExists(new_chrome_exe); 74 return file_util::PathExists(new_chrome_exe);
75 } 75 }
76 76
77 bool SwapNewChromeExeIfPresent() { 77 bool SwapNewChromeExeIfPresent() {
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 return false; 114 return false;
115 // At this point the chrome.exe has been swapped with the new one. 115 // At this point the chrome.exe has been swapped with the new one.
116 if (!RelaunchChromeBrowser(command_line)) { 116 if (!RelaunchChromeBrowser(command_line)) {
117 // The re-launch fails. Feel free to panic now. 117 // The re-launch fails. Feel free to panic now.
118 NOTREACHED(); 118 NOTREACHED();
119 } 119 }
120 return true; 120 return true;
121 } 121 }
122 122
123 } // namespace upgrade_util 123 } // namespace upgrade_util
OLDNEW
« no previous file with comments | « chrome/browser/first_run/upgrade_util_linux.cc ('k') | chrome/browser/importer/firefox_importer_unittest_utils_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698