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

Unified Diff: third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp

Issue 1377673002: Properly fix use-after-free of InputTypeViews when the type attribute is modified in the change eve… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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 | « third_party/WebKit/Source/core/html/HTMLInputElement.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp
diff --git a/third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp b/third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp
index 5e5ce039976bbd2b026853713c107e6431c1e932..2be0d9608d086caf5c0fbfb318c8b87ee08f9411 100644
--- a/third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp
+++ b/third_party/WebKit/Source/core/html/forms/CheckboxInputType.cpp
@@ -88,11 +88,6 @@ PassOwnPtrWillBeRawPtr<ClickHandlingState> CheckboxInputType::willDispatchClick(
void CheckboxInputType::didDispatchClick(Event* event, const ClickHandlingState& state)
{
- // Prevent change event handlers from indirectly freeing the
- // CheckboxInputType via a modification of the "type" attribute on the
- // HTMLInputElement.
- RefPtrWillBeRawPtr<CheckboxInputType> protect(this);
-
if (event->defaultPrevented() || event->defaultHandled()) {
element().setIndeterminate(state.indeterminate);
element().setChecked(state.checked);
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLInputElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698