Index: chrome/installer/util/google_chrome_distribution.cc |
diff --git a/chrome/installer/util/google_chrome_distribution.cc b/chrome/installer/util/google_chrome_distribution.cc |
index b340873df6e72c9e7b65820d3fa1e539319dc76e..2cb98940aba76c988208b7b620dd0f8b3de20d71 100644 |
--- a/chrome/installer/util/google_chrome_distribution.cc |
+++ b/chrome/installer/util/google_chrome_distribution.cc |
@@ -764,14 +764,20 @@ void GoogleChromeDistribution::LaunchUserExperiment( |
} |
} |
// Check browser usage inactivity by the age of the last-write time of the |
- // chrome user data directory. |
- FilePath user_data_dir(product.GetUserDataPath()); |
+ // most recently-used chrome user data directory. |
+ std::vector<FilePath> user_data_dirs; |
+ product.GetUserDataPaths(&user_data_dirs); |
+ int dir_age_hours = -1; |
+ for (size_t i = 0; i < user_data_dirs.size(); ++i) { |
+ int this_age = GetDirectoryWriteAgeInHours( |
+ user_data_dirs[i].value().c_str()); |
+ if (this_age >= 0 && (dir_age_hours < 0 || this_age < dir_age_hours)) |
+ dir_age_hours = this_age; |
+ } |
const bool experiment_enabled = false; |
const int kThirtyDays = 30 * 24; |
- int dir_age_hours = GetDirectoryWriteAgeInHours( |
- user_data_dir.value().c_str()); |
if (!experiment_enabled) { |
VLOG(1) << "Toast experiment is disabled."; |
return; |