Title: [213047] releases/WebKitGTK/webkit-2.16/Source/WebCore
- Revision
- 213047
- Author
- [email protected]
- Date
- 2017-02-27 05:24:53 -0800 (Mon, 27 Feb 2017)
Log Message
Merge r212815 - [GStreamer] Crash in MediaPlayerPrivateGStreamerMSE::buffered() when MEDIA_STREAM is disabled
https://bugs.webkit.org/show_bug.cgi?id=168662
Reviewed by Michael Catanzaro.
When MEDIA_STREAM is disabled, if MediaPlayer::loadWithNextMediaEngine is called with a current engine and
there's no type specified, the next media engine that is used is the MSE one. Since there's no actually a media
stream, the engine is created but never loaded. When buffered is called it tries to use its media source that is
nullptr. It doesn't happen when MEDIA_STREAM is enabled, because the next media engine returned is Owr that
doesn't implement buffered and always returns an empty PlatformTimeRanges.
* platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
(WebCore::MediaPlayerPrivateGStreamerMSE::buffered): Return an empty PlatformTimeRanges if m_mediaSource is nullptr.
Modified Paths
Diff
Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog (213046 => 213047)
--- releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog 2017-02-27 13:23:48 UTC (rev 213046)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog 2017-02-27 13:24:53 UTC (rev 213047)
@@ -1,3 +1,19 @@
+2017-02-22 Carlos Garcia Campos <[email protected]>
+
+ [GStreamer] Crash in MediaPlayerPrivateGStreamerMSE::buffered() when MEDIA_STREAM is disabled
+ https://bugs.webkit.org/show_bug.cgi?id=168662
+
+ Reviewed by Michael Catanzaro.
+
+ When MEDIA_STREAM is disabled, if MediaPlayer::loadWithNextMediaEngine is called with a current engine and
+ there's no type specified, the next media engine that is used is the MSE one. Since there's no actually a media
+ stream, the engine is created but never loaded. When buffered is called it tries to use its media source that is
+ nullptr. It doesn't happen when MEDIA_STREAM is enabled, because the next media engine returned is Owr that
+ doesn't implement buffered and always returns an empty PlatformTimeRanges.
+
+ * platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
+ (WebCore::MediaPlayerPrivateGStreamerMSE::buffered): Return an empty PlatformTimeRanges if m_mediaSource is nullptr.
+
2017-02-21 Chris Dumez <[email protected]>
REGRESSION (r207720): /more/conformance/conformance/quickCheckAPI-S_V.html test fails
Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp (213046 => 213047)
--- releases/WebKitGTK/webkit-2.16/Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp 2017-02-27 13:23:48 UTC (rev 213046)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp 2017-02-27 13:24:53 UTC (rev 213047)
@@ -474,7 +474,7 @@
std::unique_ptr<PlatformTimeRanges> MediaPlayerPrivateGStreamerMSE::buffered() const
{
- return m_mediaSource->buffered();
+ return m_mediaSource ? m_mediaSource->buffered() : std::make_unique<PlatformTimeRanges>();
}
void MediaPlayerPrivateGStreamerMSE::sourceChanged()
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes