Chromium Code Reviews| Index: components/arc/user_data/arc_user_data_service.cc |
| diff --git a/components/arc/user_data/arc_user_data_service.cc b/components/arc/user_data/arc_user_data_service.cc |
| index 27d42d729bc0b27044c87efc9241460aa2916e5c..5284352dea2ec8ad352d06c2b1720b92300fad5d 100644 |
| --- a/components/arc/user_data/arc_user_data_service.cc |
| +++ b/components/arc/user_data/arc_user_data_service.cc |
| @@ -4,6 +4,8 @@ |
| #include "components/arc/user_data/arc_user_data_service.h" |
| +#include "base/command_line.h" |
| +#include "chromeos/chromeos_switches.h" |
| #include "chromeos/cryptohome/cryptohome_parameters.h" |
| #include "chromeos/dbus/dbus_thread_manager.h" |
| #include "chromeos/dbus/session_manager_client.h" |
| @@ -49,7 +51,9 @@ void ArcUserDataService::ClearIfDisabled() { |
| LOG(ERROR) << "ARC instance not stopped, user data can't be cleared"; |
| return; |
| } |
| - if (arc_enabled_pref_->GetValue()) |
| + if (arc_enabled_pref_->GetValue() || |
| + base::CommandLine::ForCurrentProcess()->HasSwitch( |
| + chromeos::switches::kDisableArcDataWipe)) |
|
Yusuke Sato
2016/07/05 03:52:41
nit: can you add {}? IIUC arc/ usually uses {} whe
dspaid
2016/07/05 03:59:04
Done.
|
| return; |
| const cryptohome::Identification cryptohome_id(primary_user_account_id_); |
| chromeos::SessionManagerClient* session_manager_client = |