Index: base/strings/string_number_conversions.cc |
diff --git a/base/strings/string_number_conversions.cc b/base/strings/string_number_conversions.cc |
index fadc81a186f6631a5e5226e49a1e11b969ec2f70..c9b11156ff095e8716c15370881e7ee3e6509555 100644 |
--- a/base/strings/string_number_conversions.cc |
+++ b/base/strings/string_number_conversions.cc |
@@ -186,7 +186,9 @@ class IteratorRangeToNumber { |
} |
if (begin != end && *begin == '-') { |
- if (!Negative::Invoke(begin + 1, end, output)) { |
+ if (!std::numeric_limits<value_type>::is_signed) { |
+ valid = false; |
+ } else if (!Negative::Invoke(begin + 1, end, output)) { |
valid = false; |
} |
} else { |