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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_blocking_page.cc

Issue 3968001: Update code that previously constructed strings from string iterators only to... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 2 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
Index: chrome/browser/safe_browsing/safe_browsing_blocking_page.cc
===================================================================
--- chrome/browser/safe_browsing/safe_browsing_blocking_page.cc (revision 63369)
+++ chrome/browser/safe_browsing/safe_browsing_blocking_page.cc (working copy)
@@ -331,9 +331,10 @@
size_t colon_index = command.find(':');
if (colon_index != std::string::npos) {
DCHECK(colon_index < command.size() - 1);
- std::string index_str = command.substr(colon_index + 1);
command = command.substr(0, colon_index);
- bool result = base::StringToInt(index_str, &element_index);
+ bool result = base::StringToInt(command.begin() + colon_index + 1,
+ command.end(),
+ &element_index);
DCHECK(result);
}

Powered by Google App Engine
This is Rietveld 408576698