⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 246107 in webkit


Ignore:
Timestamp:
Jun 5, 2019, 9:41:05 AM (7 years ago)
Author:
Michael Catanzaro
Message:

[GStreamer] Crash in MediaPlayerPrivateGStreamerBase::ensureGstGLContext
https://bugs.webkit.org/show_bug.cgi?id=198567

Reviewed by Philippe Normand.

MediaPlayerPrivateGStreamerBase::ensureGstGLContext is currently a guaranteed crash because
it expects PlatformDisplay::sharedDisplayForCompositing() to return a PlatformDisplayLibWPE
if compiled with USE(WPE_RENDERER), but PlatformDisplayLibWPE has lower precedence than
PlatformDisplayX11 and PlatformDisplayWayland. When running our layout tests with
run-webkit-tests --gtk, it's guaranteed to be a PlatformDisplayX11.

I think Carlos was clearly expecting PlatformDisplayLibWPE, so I don't know what the ideal
desired behavior is, but the crashes go away if we change the code to allow any type of
PlatformDisplay. This should hopefully fix our bots, which are still exiting early.

  • platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:

(WebCore::MediaPlayerPrivateGStreamerBase::ensureGstGLContext):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r246105 r246107  
     12019-06-05  Michael Catanzaro  <mcatanzaro@igalia.com>
     2
     3        [GStreamer] Crash in MediaPlayerPrivateGStreamerBase::ensureGstGLContext
     4        https://bugs.webkit.org/show_bug.cgi?id=198567
     5
     6        Reviewed by Philippe Normand.
     7
     8        MediaPlayerPrivateGStreamerBase::ensureGstGLContext is currently a guaranteed crash because
     9        it expects PlatformDisplay::sharedDisplayForCompositing() to return a PlatformDisplayLibWPE
     10        if compiled with USE(WPE_RENDERER), but PlatformDisplayLibWPE has lower precedence than
     11        PlatformDisplayX11 and PlatformDisplayWayland. When running our layout tests with
     12        run-webkit-tests --gtk, it's guaranteed to be a PlatformDisplayX11.
     13
     14        I think Carlos was clearly expecting PlatformDisplayLibWPE, so I don't know what the ideal
     15        desired behavior is, but the crashes go away if we change the code to allow any type of
     16        PlatformDisplay. This should hopefully fix our bots, which are still exiting early.
     17
     18        * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:
     19        (WebCore::MediaPlayerPrivateGStreamerBase::ensureGstGLContext):
     20
    1212019-06-05  Zalan Bujtas  <zalan@apple.com>
    222
  • trunk/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp

    r245807 r246107  
    452452
    453453#if USE(WPE_RENDERER)
    454         ASSERT(is<PlatformDisplayLibWPE>(sharedDisplay));
    455         GST_DEBUG_OBJECT(pipeline(), "Creating WPE shared EGL display");
    456         if (shouldAdoptRef)
    457             m_glDisplay = adoptGRef(GST_GL_DISPLAY(gst_gl_display_egl_new_with_egl_display(downcast<PlatformDisplayLibWPE>(sharedDisplay).eglDisplay())));
    458         else
    459             m_glDisplay = GST_GL_DISPLAY(gst_gl_display_egl_new_with_egl_display(downcast<PlatformDisplayLibWPE>(sharedDisplay).eglDisplay()));
     454        if (is<PlatformDisplayLibWPE>(sharedDisplay)) {
     455            GST_DEBUG_OBJECT(pipeline(), "Creating WPE shared EGL display");
     456            if (shouldAdoptRef)
     457                m_glDisplay = adoptGRef(GST_GL_DISPLAY(gst_gl_display_egl_new_with_egl_display(downcast<PlatformDisplayLibWPE>(sharedDisplay).eglDisplay())));
     458            else
     459                m_glDisplay = GST_GL_DISPLAY(gst_gl_display_egl_new_with_egl_display(downcast<PlatformDisplayLibWPE>(sharedDisplay).eglDisplay()));
     460        }
    460461#endif
    461462
Note: See TracChangeset for help on using the changeset viewer.