[chromium] REGRESSION(126076) Should not touch old GraphicsLayerChromium::m_contentsLayer when setting up a new contents layer
Created attachment 159556 [details] Patch
This is caught by gpu_tests:GPUCrashTest.WebkitLoseContext on the GPU waterfall. I'm not yet sure why there are no layout tests that catch this, the test catches the issue when run in chromium without any automation hooks.
Created attachment 159557 [details] Patch
Comment on attachment 159557 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=159557&action=review This relies on setupContentsLayer() being called before any setters that touch the m_contentsLayer's properties are set, which appears to be the case. If this isn't safe enough for us we could introduce a refcounted wrapper in between the layers and GLC. > Source/WebCore/platform/graphics/chromium/GraphicsLayerChromium.cpp:-771 > - if (contentsLayer == m_contentsLayer) this is also bogus, GraphicsLayerChromium does not have ownership of m_contentsLayer so it could be deallocated and a new layer allocated at the same address
Created attachment 159563 [details] Patch
Comment on attachment 159563 [details] Patch R=me. Sounds good to me.
Please wait for approval from abarth@webkit.org, dglazkov@chromium.org, fishd@chromium.org, jamesr@chromium.org or tkent@chromium.org before submitting, as this patch contains changes to the Chromium public API. See also https://trac.webkit.org/wiki/ChromiumWebKitAPI.
Committed r126099: <http://trac.webkit.org/changeset/126099>