WebKit Bugzilla
Attachment 340602 Details for
Bug 185725
: [GStreamer] Don't set the ReadyState to HaveNothing when an error occurs in the playback pipeline
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185725-20180517195820.patch (text/plain), 3.68 KB, created by
Yacine Bandou
on 2018-05-17 10:58:18 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Yacine Bandou
Created:
2018-05-17 10:58:18 PDT
Size:
3.68 KB
patch
obsolete
>Subversion Revision: 231637 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 5b64ca863c11ceaa6671109508b8ce6fbb0ce6bb..86c5e969b8b10af1827c38443681bcee346f3745 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,25 @@ >+2018-05-17 Yacine Bandou <yacine.bandou_ext@softathome.com> >+ >+ [MSE][GStreamer] Don't set the ReadyState to HaveNothing when an error occurs in the playback pipeline >+ https://bugs.webkit.org/show_bug.cgi?id=185725 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ This patch fixes the crash of some WPT encrypted-media tests like: >+ - clearkey-mp4-playback-temporary-multikey-sequential.https.html >+ - clearkey-mp4-playback-temporary-clear-encrypted.https.html >+ >+ These crashes should be fixed in 185242 but unfortunately it isn't the case. See bug 185242 for more details. >+ >+ When an error occurs in playback pipeline like no decipher key, in case of encrypted content, the MediaPlayerPrivateGstreamer sets NetworkState to FormatError >+ which causes the detachment of MediaElement from MediaSource, then MediaPlayerPrivateGstreamer sets the ReadyState to HaveNothing which causes a trying again >+ to play the same URI, thus the crash occurs because the MediaElement is detached from MediaSource, see bugzilla for more details. >+ >+ * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: >+ (WebCore::MediaPlayerPrivateGStreamer::handleMessage): >+ (WebCore::MediaPlayerPrivateGStreamer::playingFailed): >+ * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: >+ > 2018-05-10 Yacine Bandou <yacine.bandou_ext@softathome.com> > > [EME][GStreamer] Handle the protection event in MediaPlayerPrivate >diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp >index ce0ab819e4c328e55904f9ef698bb9eaac9acc07..02207b8af7e44291281b4d3572f59a0c76ce4289 100644 >--- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp >+++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp >@@ -1156,7 +1156,8 @@ void MediaPlayerPrivateGStreamer::handleMessage(GstMessage* message) > if (attemptNextLocation) > issueError = !loadNextLocation(); > if (issueError) >- loadingFailed(error); >+ playingFailed(error); >+ > break; > case GST_MESSAGE_EOS: > didEnd(); >@@ -2131,6 +2132,17 @@ void MediaPlayerPrivateGStreamer::loadingFailed(MediaPlayer::NetworkState error) > m_readyTimerHandler.stop(); > } > >+void MediaPlayerPrivateGStreamer::playingFailed(MediaPlayer::NetworkState error) >+{ >+ GST_WARNING("Playing failed, error: %d", error); >+ >+ m_errorOccured = true; >+ if (m_networkState != error) { >+ m_networkState = error; >+ m_player->networkStateChanged(); >+ } >+} >+ > static HashSet<String, ASCIICaseInsensitiveHash>& mimeTypeSet() > { > static NeverDestroyed<HashSet<String, ASCIICaseInsensitiveHash>> mimeTypes = []() >diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h >index b78046148d9a958c5303959705a9e49105909cc5..04d4c88325148efb9dc34f5eb91079249a058459 100644 >--- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h >+++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h >@@ -115,6 +115,7 @@ public: > void didEnd(); > virtual void durationChanged(); > void loadingFailed(MediaPlayer::NetworkState); >+ void playingFailed(MediaPlayer::NetworkState); > > virtual void sourceSetup(GstElement*); >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185725
:
340602
|
340790
|
340950