Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1431)

Unified Diff: chrome/browser/push_messaging/push_messaging_app_identifier.cc

Issue 1240183002: Update SplitString calls in chrome. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/profiles/profile_downloader.cc ('k') | chrome/browser/safe_browsing/chunk_range.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/push_messaging/push_messaging_app_identifier.cc
diff --git a/chrome/browser/push_messaging/push_messaging_app_identifier.cc b/chrome/browser/push_messaging/push_messaging_app_identifier.cc
index fa15b9468950343944fa1adca15aa74ae085b2d5..cfb8c5f1732b1d9a9f7c857acef0acd07b082c80 100644
--- a/chrome/browser/push_messaging/push_messaging_app_identifier.cc
+++ b/chrome/browser/push_messaging/push_messaging_app_identifier.cc
@@ -37,8 +37,9 @@ std::string MakePrefValue(const GURL& origin,
bool GetOriginAndSWRFromPrefValue(
const std::string& pref_value, GURL* origin,
int64_t* service_worker_registration_id) {
- std::vector<std::string> parts;
- base::SplitString(pref_value, kSeparator, &parts);
+ std::vector<std::string> parts = base::SplitString(
+ pref_value, std::string(1, kSeparator),
+ base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL);
if (parts.size() != 2)
return false;
« no previous file with comments | « chrome/browser/profiles/profile_downloader.cc ('k') | chrome/browser/safe_browsing/chunk_range.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698