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

Unified Diff: third_party/WebKit/Source/core/html/HTMLInputElement.cpp

Issue 2452743004: INPUT element: Fix integer overflow in input.stepDown(). (Closed)
Patch Set: Created 4 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: third_party/WebKit/Source/core/html/HTMLInputElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
index 8642efce92e9f48d25823d94c16738ebd327937d..6003caf836cee6b34574dee6ba35a5443099edcb 100644
--- a/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLInputElement.cpp
@@ -280,7 +280,7 @@ void HTMLInputElement::stepUp(int n, ExceptionState& exceptionState) {
}
void HTMLInputElement::stepDown(int n, ExceptionState& exceptionState) {
- m_inputType->stepUp(-n, exceptionState);
+ m_inputType->stepUp(-1.0 * n, exceptionState);
}
void HTMLInputElement::blur() {

Powered by Google App Engine
This is Rietveld 408576698