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

Unified Diff: chrome/installer/util/eula_util.cc

Issue 208393020: Fix the new First Run sentinel file path determination. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync and rebase; re-upload to kick CQ. Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/installer/util/eula_util.cc
diff --git a/chrome/installer/util/eula_util.cc b/chrome/installer/util/eula_util.cc
index 9bbf5029810aaa276e7d65fd1bed62d1a5e4ea41..e1051e44b378cfc5d868780d6988b4f1d491f912 100644
--- a/chrome/installer/util/eula_util.cc
+++ b/chrome/installer/util/eula_util.cc
@@ -6,7 +6,6 @@
#include "base/file_util.h"
#include "base/memory/scoped_ptr.h"
-#include "chrome/common/chrome_constants.h"
#include "chrome/installer/util/browser_distribution.h"
#include "chrome/installer/util/install_util.h"
#include "chrome/installer/util/installation_state.h"
@@ -18,16 +17,6 @@ namespace installer {
namespace {
-bool IsChromeFirstRunPending(BrowserDistribution* dist) {
- // Chrome creates the first run sentinel after the user has gone through the
- // first-run flow. Assume Chrome has been run if the path to the sentinel
- // cannot be determined.
- base::FilePath first_run_sentinel;
- return InstallUtil::GetSentinelFilePath(chrome::kFirstRunSentinel, dist,
- &first_run_sentinel) &&
- !base::PathExists(first_run_sentinel);
-}
-
bool IsEULAAcceptanceFlagged(BrowserDistribution* dist) {
// Chrome creates the EULA sentinel after the EULA has been accepted when
// doing so is required by master_preferences. Assume the EULA has not been
@@ -88,7 +77,7 @@ EULAAcceptanceResponse IsEULAAccepted(bool system_level) {
if (prod_state.GetEulaAccepted(&eula_accepted) && !eula_accepted)
return QUERY_EULA_NOT_ACCEPTED;
- if (!IsChromeFirstRunPending(dist) || IsEULAAcceptanceFlagged(dist))
+ if (InstallUtil::IsFirstRunSentinelPresent() || IsEULAAcceptanceFlagged(dist))
return QUERY_EULA_ACCEPTED;
// EULA acceptance not flagged. Now see if it is required.

Powered by Google App Engine
This is Rietveld 408576698