Changeset 117829 in webkit
- Timestamp:
- May 21, 2012, 4:26:57 PM (14 years ago)
- Location:
- branches/safari-536-branch
- Files:
-
- 3 edited
- 2 copied
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/fast/dom/HTMLSelectElement/option-add-crash-expected.txt (copied) (copied from trunk/LayoutTests/fast/dom/HTMLSelectElement/option-add-crash-expected.txt )
-
LayoutTests/fast/dom/HTMLSelectElement/option-add-crash.html (copied) (copied from trunk/LayoutTests/fast/dom/HTMLSelectElement/option-add-crash.html )
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/html/HTMLSelectElement.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-536-branch/LayoutTests/ChangeLog
r117180 r117829 1 2012-05-21 Lucas Forschler <lforschler@apple.com> 2 3 Merge 116864 4 5 2012-05-12 Abhishek Arya <inferno@chromium.org> 6 7 Crash in HTMLSelectElement::setOption 8 https://bugs.webkit.org/show_bug.cgi?id=85420 9 10 Reviewed by Eric Seidel. 11 12 * fast/dom/HTMLSelectElement/option-add-crash-expected.txt: Added. 13 * fast/dom/HTMLSelectElement/option-add-crash.html: Added. 14 1 15 2012-05-15 Lucas Forschler <lforschler@apple.com> 2 16 -
branches/safari-536-branch/Source/WebCore/ChangeLog
r117364 r117829 1 2012-05-21 Lucas Forschler <lforschler@apple.com> 2 3 Merge 116864 4 5 2012-05-12 Abhishek Arya <inferno@chromium.org> 6 7 Crash in HTMLSelectElement::setOption 8 https://bugs.webkit.org/show_bug.cgi?id=85420 9 10 Reviewed by Eric Seidel 11 12 RefPtr before option in HTMLSelectElement::setOption since it 13 can get destroyed due to mutation events. 14 15 Test: fast/dom/HTMLSelectElement/option-add-crash.html 16 17 * html/HTMLSelectElement.cpp: 18 (WebCore::HTMLSelectElement::setOption): 19 1 20 2012-05-16 Lucas Forschler <lforschler@apple.com> 2 21 -
branches/safari-536-branch/Source/WebCore/html/HTMLSelectElement.cpp
r114870 r117829 414 414 index = maxSelectItems - 1; 415 415 int diff = index - length(); 416 HTMLElement*before = 0;416 RefPtr<HTMLElement> before = 0; 417 417 // Out of array bounds? First insert empty dummies. 418 418 if (diff > 0) { … … 425 425 // Finally add the new element. 426 426 if (!ec) { 427 add(option, before , ec);427 add(option, before.get(), ec); 428 428 if (diff >= 0 && option->selected()) 429 429 optionSelectionStateChanged(option, true);
Note:
See TracChangeset
for help on using the changeset viewer.