Chromium Code Reviews| Index: cloud_print/service/win/chrome_launcher.cc |
| diff --git a/cloud_print/service/win/chrome_launcher.cc b/cloud_print/service/win/chrome_launcher.cc |
| index adf9c24de363e899aea62edb146d7c70d6b7ba52..fd541913a8d20890efdba1ff3d843dde5a5e12c5 100644 |
| --- a/cloud_print/service/win/chrome_launcher.cc |
| +++ b/cloud_print/service/win/chrome_launcher.cc |
| @@ -10,6 +10,7 @@ |
| #include "base/files/scoped_temp_dir.h" |
| #include "base/json/json_reader.h" |
| #include "base/json/json_writer.h" |
| +#include "base/path_service.h" |
| #include "base/process/process.h" |
| #include "base/process/process.h" |
| #include "base/values.h" |
| @@ -17,6 +18,7 @@ |
| #include "base/win/scoped_handle.h" |
| #include "base/win/scoped_process_information.h" |
| #include "chrome/common/chrome_constants.h" |
| +#include "chrome/common/chrome_paths.h" |
| #include "chrome/common/chrome_switches.h" |
| #include "chrome/common/pref_names.h" |
| #include "chrome/installer/launcher_support/chrome_launcher_support.h" |
| @@ -155,8 +157,9 @@ void DeleteAutorunKeys(const base::FilePath& user_data_dir) { |
| if (cmd.GetSwitchValueASCII(switches::kProcessType) == |
| switches::kServiceProcess && |
| cmd.HasSwitch(switches::kUserDataDir)) { |
| - base::FilePath path_from_reg = base::MakeAbsoluteFilePath( |
| - cmd.GetSwitchValuePath(switches::kUserDataDir)); |
|
grt (UTC plus 2)
2015/03/26 18:36:22
i wouldn't touch this one. it seems to me that clo
noms (inactive)
2015/03/30 14:06:33
Done.
|
| + base::FilePath dir; |
| + PathService::Get(chrome::DIR_USER_DATA, &dir); |
| + base::FilePath path_from_reg = base::MakeAbsoluteFilePath(dir); |
| if (path_from_reg == abs_user_data_dir) { |
| to_delete.push_back(value.Name()); |
| } |