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

Unified Diff: chrome/browser/autocomplete_history_manager.cc

Issue 8984007: Revert 114929 - Standardize StringToInt{,64} interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years 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 | « base/string_piece.h ('k') | chrome/browser/component_updater/component_updater_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/autocomplete_history_manager.cc
===================================================================
--- chrome/browser/autocomplete_history_manager.cc (revision 114929)
+++ chrome/browser/autocomplete_history_manager.cc (working copy)
@@ -19,7 +19,6 @@
#include "content/browser/tab_contents/tab_contents.h"
#include "webkit/forms/form_data.h"
-using base::StringPiece16;
using webkit::forms::FormData;
using webkit::forms::FormField;
@@ -64,32 +63,26 @@
return false;
int area;
- if (!base::StringToInt(StringPiece16(number_string.begin(),
- number_string.begin() + 3),
- &area)) {
+ if (!base::StringToInt(number_string.begin(),
+ number_string.begin() + 3,
+ &area))
return false;
- }
if (area < 1 ||
area == 666 ||
- area >= 900) {
+ area >= 900)
return false;
- }
int group;
- if (!base::StringToInt(StringPiece16(number_string.begin() + 3,
- number_string.begin() + 5),
- &group)
- || group == 0) {
+ if (!base::StringToInt(number_string.begin() + 3,
+ number_string.begin() + 5,
+ &group) || group == 0)
return false;
- }
int serial;
- if (!base::StringToInt(StringPiece16(number_string.begin() + 5,
- number_string.begin() + 9),
- &serial)
- || serial == 0) {
+ if (!base::StringToInt(number_string.begin() + 5,
+ number_string.begin() + 9,
+ &serial) || serial == 0)
return false;
- }
return true;
}
« no previous file with comments | « base/string_piece.h ('k') | chrome/browser/component_updater/component_updater_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698