diff options
Diffstat (limited to 'chromeos')
-rw-r--r-- | chromeos/dbus/dbus_client_bundle.cc | 2 | ||||
-rw-r--r-- | chromeos/dbus/dbus_thread_manager.cc | 8 | ||||
-rw-r--r-- | chromeos/dbus/fake_shill_manager_client.cc | 2 | ||||
-rw-r--r-- | chromeos/dbus/fake_sms_client.cc | 4 | ||||
-rw-r--r-- | chromeos/dbus/power_manager_client.cc | 2 | ||||
-rw-r--r-- | chromeos/dbus/update_engine_client.cc | 3 | ||||
-rw-r--r-- | chromeos/login/login_state.cc | 3 | ||||
-rw-r--r-- | chromeos/network/network_sms_handler_unittest.cc | 2 | ||||
-rw-r--r-- | chromeos/process_proxy/process_proxy.cc | 4 | ||||
-rw-r--r-- | chromeos/settings/cros_settings_provider.cc | 3 | ||||
-rw-r--r-- | chromeos/system/statistics_provider.cc | 4 | ||||
-rw-r--r-- | chromeos/tools/onc_validator/onc_validator.cc | 7 |
12 files changed, 24 insertions, 20 deletions
diff --git a/chromeos/dbus/dbus_client_bundle.cc b/chromeos/dbus/dbus_client_bundle.cc index 1293f84..f80e2d29 100644 --- a/chromeos/dbus/dbus_client_bundle.cc +++ b/chromeos/dbus/dbus_client_bundle.cc @@ -222,7 +222,7 @@ DBusClientBundle::DBusClientBundle(DBusClientTypeMask unstub_client_mask) } else { FakeGsmSMSClient* gsm_sms_client = new FakeGsmSMSClient(); gsm_sms_client->set_sms_test_message_switch_present( - CommandLine::ForCurrentProcess()->HasSwitch( + base::CommandLine::ForCurrentProcess()->HasSwitch( chromeos::switches::kSmsTestMessages)); gsm_sms_client_.reset(gsm_sms_client); } diff --git a/chromeos/dbus/dbus_thread_manager.cc b/chromeos/dbus/dbus_thread_manager.cc index a42a7b0..fdcc202 100644 --- a/chromeos/dbus/dbus_thread_manager.cc +++ b/chromeos/dbus/dbus_thread_manager.cc @@ -354,14 +354,14 @@ void DBusThreadManager::Initialize() { CHECK(!g_dbus_thread_manager); bool use_dbus_stub = !base::SysInfo::IsRunningOnChromeOS() || - CommandLine::ForCurrentProcess()->HasSwitch( - chromeos::switches::kDbusStub); - bool force_unstub_clients = CommandLine::ForCurrentProcess()->HasSwitch( + base::CommandLine::ForCurrentProcess()->HasSwitch( + chromeos::switches::kDbusStub); + bool force_unstub_clients = base::CommandLine::ForCurrentProcess()->HasSwitch( chromeos::switches::kDbusUnstubClients); // Determine whether we use stub or real client implementations. if (force_unstub_clients) { InitializeWithPartialStub( - CommandLine::ForCurrentProcess()->GetSwitchValueASCII( + base::CommandLine::ForCurrentProcess()->GetSwitchValueASCII( chromeos::switches::kDbusUnstubClients)); } else if (use_dbus_stub) { InitializeWithStubs(); diff --git a/chromeos/dbus/fake_shill_manager_client.cc b/chromeos/dbus/fake_shill_manager_client.cc index 2ef8327..7a8e633 100644 --- a/chromeos/dbus/fake_shill_manager_client.cc +++ b/chromeos/dbus/fake_shill_manager_client.cc @@ -977,7 +977,7 @@ void FakeShillManagerClient::ParseCommandLineSwitch() { SetInitialNetworkState(shill::kTypeVPN, shill::kStateIdle); // Parse additional options - CommandLine* command_line = CommandLine::ForCurrentProcess(); + base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); if (!command_line->HasSwitch(switches::kShillStub)) return; diff --git a/chromeos/dbus/fake_sms_client.cc b/chromeos/dbus/fake_sms_client.cc index eb3c8ab..6f2c996 100644 --- a/chromeos/dbus/fake_sms_client.cc +++ b/chromeos/dbus/fake_sms_client.cc @@ -26,8 +26,8 @@ void FakeSMSClient::Init(dbus::Bus* bus) {} void FakeSMSClient::GetAll(const std::string& service_name, const dbus::ObjectPath& object_path, const GetAllCallback& callback) { - if (!CommandLine::ForCurrentProcess()->HasSwitch( - chromeos::switches::kSmsTestMessages)) + if (!base::CommandLine::ForCurrentProcess()->HasSwitch( + chromeos::switches::kSmsTestMessages)) return; // Ownership passed to callback diff --git a/chromeos/dbus/power_manager_client.cc b/chromeos/dbus/power_manager_client.cc index d1c9f2c..374af7f 100644 --- a/chromeos/dbus/power_manager_client.cc +++ b/chromeos/dbus/power_manager_client.cc @@ -957,7 +957,7 @@ class PowerManagerClientStubImpl : public PowerManagerClient { } void ParseCommandLineSwitch() { - CommandLine* command_line = CommandLine::ForCurrentProcess(); + base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); if (!command_line || !command_line->HasSwitch(switches::kPowerStub)) return; std::string option_str = diff --git a/chromeos/dbus/update_engine_client.cc b/chromeos/dbus/update_engine_client.cc index 19f3e06..321b247 100644 --- a/chromeos/dbus/update_engine_client.cc +++ b/chromeos/dbus/update_engine_client.cc @@ -564,7 +564,8 @@ UpdateEngineClient* UpdateEngineClient::Create( if (type == REAL_DBUS_CLIENT_IMPLEMENTATION) return new UpdateEngineClientImpl(); DCHECK_EQ(STUB_DBUS_CLIENT_IMPLEMENTATION, type); - if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kTestAutoUpdateUI)) + if (base::CommandLine::ForCurrentProcess()->HasSwitch( + switches::kTestAutoUpdateUI)) return new UpdateEngineClientFakeImpl(); else return new UpdateEngineClientStubImpl(); diff --git a/chromeos/login/login_state.cc b/chromeos/login/login_state.cc index 04f72a3..ae8403c 100644 --- a/chromeos/login/login_state.cc +++ b/chromeos/login/login_state.cc @@ -19,7 +19,8 @@ namespace { // logged in. bool AlwaysLoggedInByDefault() { return !base::SysInfo::IsRunningOnChromeOS() && - !CommandLine::ForCurrentProcess()->HasSwitch(switches::kLoginManager); + !base::CommandLine::ForCurrentProcess()->HasSwitch( + switches::kLoginManager); } } // namespace diff --git a/chromeos/network/network_sms_handler_unittest.cc b/chromeos/network/network_sms_handler_unittest.cc index 199e70f..8550b60 100644 --- a/chromeos/network/network_sms_handler_unittest.cc +++ b/chromeos/network/network_sms_handler_unittest.cc @@ -56,7 +56,7 @@ class NetworkSmsHandlerTest : public testing::Test { virtual void SetUp() override { // Append '--sms-test-messages' to the command line to tell // SMSClientStubImpl to generate a series of test SMS messages. - CommandLine* command_line = CommandLine::ForCurrentProcess(); + base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); command_line->AppendSwitch(chromeos::switches::kSmsTestMessages); // Initialize DBusThreadManager with a stub implementation. diff --git a/chromeos/process_proxy/process_proxy.cc b/chromeos/process_proxy/process_proxy.cc index b1021f4..913f074 100644 --- a/chromeos/process_proxy/process_proxy.cc +++ b/chromeos/process_proxy/process_proxy.cc @@ -231,8 +231,8 @@ bool ProcessProxy::LaunchProcess(const std::string& command, int slave_fd, options.environ["TERM"] = "xterm"; // Launch the process. - return base::LaunchProcess(CommandLine(base::FilePath(command)), options, - pid); + return base::LaunchProcess(base::CommandLine(base::FilePath(command)), + options, pid); } void ProcessProxy::CloseAllFdPairs() { diff --git a/chromeos/settings/cros_settings_provider.cc b/chromeos/settings/cros_settings_provider.cc index 66ca64c..98faf71 100644 --- a/chromeos/settings/cros_settings_provider.cc +++ b/chromeos/settings/cros_settings_provider.cc @@ -25,7 +25,8 @@ void CrosSettingsProvider::Set(const std::string& path, // We don't allow changing any of the cros settings without prefix // "cros.session." in the guest mode. // It should not reach here from UI in the guest mode, but just in case. - if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kGuestSession) && + if (base::CommandLine::ForCurrentProcess()->HasSwitch( + switches::kGuestSession) && !::StartsWithASCII(path, "cros.session.", true)) { LOG(ERROR) << "Ignoring the guest request to change: " << path; return; diff --git a/chromeos/system/statistics_provider.cc b/chromeos/system/statistics_provider.cc index e533dd7..7ac8863 100644 --- a/chromeos/system/statistics_provider.cc +++ b/chromeos/system/statistics_provider.cc @@ -62,7 +62,7 @@ const char kVpdDelim[] = "\n"; const int kTimeoutSecs = 3; // The location of OEM manifest file used to trigger OOBE flow for kiosk mode. -const CommandLine::CharType kOemManifestFilePath[] = +const base::CommandLine::CharType kOemManifestFilePath[] = FILE_PATH_LITERAL("/usr/share/oem/oobe/manifest.json"); } // namespace @@ -298,7 +298,7 @@ void StatisticsProviderImpl::LoadMachineStatistics(bool load_oem_manifest) { if (load_oem_manifest) { // If kAppOemManifestFile switch is specified, load OEM Manifest file. - CommandLine* command_line = CommandLine::ForCurrentProcess(); + base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); if (command_line->HasSwitch(switches::kAppOemManifestFile)) { LoadOemManifestFromFile( command_line->GetSwitchValuePath(switches::kAppOemManifestFile)); diff --git a/chromeos/tools/onc_validator/onc_validator.cc b/chromeos/tools/onc_validator/onc_validator.cc index fab8b4a..d47597e 100644 --- a/chromeos/tools/onc_validator/onc_validator.cc +++ b/chromeos/tools/onc_validator/onc_validator.cc @@ -107,10 +107,11 @@ scoped_ptr<base::DictionaryValue> ReadDictionary(std::string filename) { } int main(int argc, const char* argv[]) { - CommandLine::Init(argc, argv); + base::CommandLine::Init(argc, argv); - const CommandLine& command_line = *CommandLine::ForCurrentProcess(); - CommandLine::StringVector args = command_line.GetArgs(); + const base::CommandLine& command_line = + *base::CommandLine::ForCurrentProcess(); + base::CommandLine::StringVector args = command_line.GetArgs(); if (args.size() != 2) { PrintHelp(); return kStatusArgumentError; |