summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/fake_shill_service_client.cc
diff options
context:
space:
mode:
authorbrettw <brettw@chromium.org>2015-07-16 16:57:33 -0700
committerCommit bot <commit-bot@chromium.org>2015-07-16 23:58:34 +0000
commit955093110ad64d5ec6f5426991efaa4a680b5d6f (patch)
tree19368cdb8861595640715e1072789959729efc2d /chromeos/dbus/fake_shill_service_client.cc
parent387e05a79c7ae346ba7db36977ddfca7ca6f10a3 (diff)
downloadchromium_src-955093110ad64d5ec6f5426991efaa4a680b5d6f.zip
chromium_src-955093110ad64d5ec6f5426991efaa4a680b5d6f.tar.gz
chromium_src-955093110ad64d5ec6f5426991efaa4a680b5d6f.tar.bz2
Remove legacy StartsWithASCII function.
This replaces it with base::StartsWith and the appropriate case flag. Since the existing version only ever did case-insensitive tests in ASCII, there should be no behavior change. BUG=506255 TBR=jam Review URL: https://codereview.chromium.org/1242023005 Cr-Commit-Position: refs/heads/master@{#339175}
Diffstat (limited to 'chromeos/dbus/fake_shill_service_client.cc')
-rw-r--r--chromeos/dbus/fake_shill_service_client.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/chromeos/dbus/fake_shill_service_client.cc b/chromeos/dbus/fake_shill_service_client.cc
index 990a37b..f0cf5ad 100644
--- a/chromeos/dbus/fake_shill_service_client.cc
+++ b/chromeos/dbus/fake_shill_service_client.cc
@@ -407,16 +407,16 @@ bool FakeShillServiceClient::SetServiceProperty(const std::string& service_path,
base::DictionaryValue new_properties;
std::string changed_property;
- bool case_sensitive = true;
- if (base::StartsWithASCII(property, "Provider.", case_sensitive) ||
- base::StartsWithASCII(property, "OpenVPN.", case_sensitive) ||
- base::StartsWithASCII(property, "L2TPIPsec.", case_sensitive)) {
+ base::CompareCase case_sensitive = base::CompareCase::SENSITIVE;
+ if (base::StartsWith(property, "Provider.", case_sensitive) ||
+ base::StartsWith(property, "OpenVPN.", case_sensitive) ||
+ base::StartsWith(property, "L2TPIPsec.", case_sensitive)) {
// These properties are only nested within the Provider dictionary if read
// from Shill. Properties that start with "Provider" need to have that
// stripped off, other properties are nested in the "Provider" dictionary
// as-is.
std::string key = property;
- if (base::StartsWithASCII(property, "Provider.", case_sensitive))
+ if (base::StartsWith(property, "Provider.", case_sensitive))
key = property.substr(strlen("Provider."));
base::DictionaryValue* provider = new base::DictionaryValue;
provider->SetWithoutPathExpansion(key, value.DeepCopy());