<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - [Cairo] Crash in GraphicsContext::drawFocusRing when painting is disabled"
   href="https://bugs.webkit.org/show_bug.cgi?id=156785">156785</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[Cairo] Crash in GraphicsContext::drawFocusRing when painting is disabled
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>WebKit Local Build
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Unspecified
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Unspecified
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Keywords</th>
          <td>Cairo
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Platform
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned&#64;lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>cgarcia&#64;igalia.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>bugs-noreply&#64;webkitgtk.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>This happens for example when view state changes to focus and paint is called from FrameView::updateControlTints() with a graphics context that doesn't have a platform context. Layout test fast/images/image-map-outline-with-scale-transform.html sometimes crashes because of this, see the bt:

Program received signal SIGSEGV, Segmentation fault.
0x00007fd378267933 in WebCore::GraphicsContext::platformContext() const () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
(gdb) bt
#0  0x00007fd378267933 in WebCore::GraphicsContext::platformContext() const () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#1  0x00007fd3782699d1 in WebCore::GraphicsContext::drawFocusRing(WebCore::Path const&amp;, float, float, WebCore::Color const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#2  0x00007fd377e93c15 in WebCore::RenderImage::paintAreaElementFocusRing(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#3  0x00007fd377e52d2d in WebCore::RenderElement::paintAsInlineBlock(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#4  0x00007fd377dbb554 in WebCore::InlineElementBox::paint(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;, WebCore::LayoutUnit, WebCore::LayoutUnit) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#5  0x00007fd377dc5da8 in WebCore::InlineFlowBox::paint(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;, WebCore::LayoutUnit, WebCore::LayoutUnit) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#6  0x00007fd377f90704 in WebCore::RootInlineBox::paint(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;, WebCore::LayoutUnit, WebCore::LayoutUnit) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#7  0x00007fd377edf0db in WebCore::RenderLineBoxList::paint(WebCore::RenderBoxModelObject*, WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) const ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#8  0x00007fd377dd3631 in WebCore::RenderBlock::paintContents(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#9  0x00007fd377ddd316 in WebCore::RenderBlock::paintObject(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#10 0x00007fd377dd1882 in WebCore::RenderBlock::paint(WebCore::PaintInfo&amp;, WebCore::LayoutPoint const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#11 0x00007fd377ead1dd in WebCore::RenderLayer::paintForegroundForFragmentsWithPhase(WebCore::PaintPhase, WTF::Vector&lt;WebCore::LayerFragment, 1ul, WTF::CrashOnOverflow, 16ul&gt; const&amp;, WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int, WebCore::RenderObject*) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#12 0x00007fd377eb1e36 in WebCore::RenderLayer::paintForegroundForFragments(WTF::Vector&lt;WebCore::LayerFragment, 1ul, WTF::CrashOnOverflow, 16ul&gt; const&amp;, WebCore::GraphicsContext&amp;, WebCore::GraphicsContext&amp;, WebCore::LayoutRect const&amp;, bool, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int, WebCore::RenderObject*, bool) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#13 0x00007fd377ec0d8d in WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#14 0x00007fd377ec1382 in WebCore::RenderLayer::paintLayerByApplyingTransform(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int, WebCore::LayoutSize const&amp;) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#15 0x00007fd377ec1ad0 in WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#16 0x00007fd377ec2445 in WebCore::RenderLayer::paintList(WTF::Vector&lt;WebCore::RenderLayer*, 0ul, WTF::CrashOnOverflow, 16ul&gt;*, WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#17 0x00007fd377ec0ae7 in WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#18 0x00007fd377ec1c40 in WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#19 0x00007fd377ec2445 in WebCore::RenderLayer::paintList(WTF::Vector&lt;WebCore::RenderLayer*, 0ul, WTF::CrashOnOverflow, 16ul&gt;*, WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#20 0x00007fd377ec0ae7 in WebCore::RenderLayer::paintLayerContents(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#21 0x00007fd377ec1c40 in WebCore::RenderLayer::paintLayer(WebCore::GraphicsContext&amp;, WebCore::RenderLayer::LayerPaintingInfo const&amp;, unsigned int) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#22 0x00007fd377ec1dcd in WebCore::RenderLayer::paint(WebCore::GraphicsContext&amp;, WebCore::LayoutRect const&amp;, WebCore::LayoutSize const&amp;, unsigned int, WebCore::RenderObject*, unsigned int)
    () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#23 0x00007fd377bbf6fc in WebCore::FrameView::paintContents(WebCore::GraphicsContext&amp;, WebCore::IntRect const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#24 0x00007fd377c709f2 in WebCore::ScrollView::paint(WebCore::GraphicsContext&amp;, WebCore::IntRect const&amp;) ()
---Type &lt;return&gt; to continue, or q &lt;return&gt; to quit---
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#25 0x00007fd377bc35cf in WebCore::FrameView::paintControlTints() () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#26 0x00007fd377bc3678 in WebCore::FrameView::updateControlTints() () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#27 0x00007fd377baf488 in WebCore::FocusController::setActiveInternal(bool) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#28 0x00007fd377baf635 in WebCore::FocusController::setViewState(unsigned int) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#29 0x00007fd377bd7548 in WebCore::Page::setViewState(unsigned int) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#30 0x00007fd377228337 in WebKit::WebPage::setViewState(unsigned int, bool, WTF::Vector&lt;unsigned long, 0ul, WTF::CrashOnOverflow, 16ul&gt; const&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#31 0x00007fd377353105 in void IPC::handleMessage&lt;Messages::WebPage::SetViewState, WebKit::WebPage, void (WebKit::WebPage::*)(unsigned int, bool, WTF::Vector&lt;unsigned long, 0ul, WTF::CrashOnOverflow, 16ul&gt; const&amp;)&gt;(IPC::MessageDecoder&amp;, WebKit::WebPage*, void (WebKit::WebPage::*)(unsigned int, bool, WTF::Vector&lt;unsigned long, 0ul, WTF::CrashOnOverflow, 16ul&gt; const&amp;)) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#32 0x00007fd377350e44 in WebKit::WebPage::didReceiveWebPageMessage(IPC::Connection&amp;, IPC::MessageDecoder&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#33 0x00007fd37705d8f9 in IPC::MessageReceiverMap::dispatchMessage(IPC::Connection&amp;, IPC::MessageDecoder&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#34 0x00007fd377187bc6 in WebKit::WebProcess::didReceiveMessage(IPC::Connection&amp;, IPC::MessageDecoder&amp;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#35 0x00007fd377059d26 in IPC::Connection::dispatchMessage(std::unique_ptr&lt;IPC::MessageDecoder, std::default_delete&lt;IPC::MessageDecoder&gt; &gt;) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#36 0x00007fd37705a683 in IPC::Connection::dispatchOneMessage() () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#37 0x00007fd375cd0ccf in WTF::RunLoop::performWork() () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libjavascriptcoregtk-4.0.so.18
#38 0x00007fd375d00539 in WTF::RunLoop::RunLoop()::{lambda(void*)#1}::_FUN(void*) () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libjavascriptcoregtk-4.0.so.18
#39 0x00007fd370f3fb8a in g_main_dispatch (context=0x13b1880) at gmain.c:3154
#40 g_main_context_dispatch (context=context&#64;entry=0x13b1880) at gmain.c:3769
#41 0x00007fd370f3ff08 in g_main_context_iterate (context=0x13b1880, block=block&#64;entry=1, dispatch=dispatch&#64;entry=1, self=&lt;optimized out&gt;) at gmain.c:3840
#42 0x00007fd370f40222 in g_main_loop_run (loop=0x1cab8c0) at gmain.c:4034
#43 0x00007fd375d00e70 in WTF::RunLoop::run() () from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libjavascriptcoregtk-4.0.so.18
#44 0x00007fd377305992 in int WebKit::ChildProcessMain&lt;WebKit::WebProcess, WebKit::WebProcessMain&gt;(int, char**) ()
   from /home/cgarcia/src/git/gnome/WebKit/WebKitBuild/Release/lib/libwebkit2gtk-4.0.so.37
#45 0x00007fd36c090610 in __libc_start_main (main=0x400af0 &lt;main&gt;, argc=2, argv=0x7ffecfbb2c78, init=&lt;optimized out&gt;, fini=&lt;optimized out&gt;, rtld_fini=&lt;optimized out&gt;, 
    stack_end=0x7ffecfbb2c68) at libc-start.c:291
#46 0x0000000000400b49 in _start ()</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>