Heap-use-after-free in WebCore::RenderLayer::addChild
https://bugs.webkit.org/show_bug.cgi?id=79698
Reviewed by Simon Fraser.
Source/WebCore:
This patch fixes a regression introduced in r108659.
The reflection layer was moved to the parent by mistake. It was then
deleted and the parent was left holding on to a deleted pointer. This
patch restores the location where reflection layer is removed - before
moving the child layers.
Test: fast/reflections/toggle-reflection-crash.html
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::removeOnlyThisLayer):
LayoutTests:
* fast/reflections/toggle-reflection-crash-expected.txt: Added.
* fast/reflections/toggle-reflection-crash.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@109125 268f45cc-cd09-0410-ab3c-d52691b4dbfc
5 files changed