Bug 138425 - [GStreamer] the webkitwebsrc element can stale
Summary: [GStreamer] the webkitwebsrc element can stale
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-05 08:54 PST by Xavier Claessens
Modified: 2014-12-15 07:37 PST (History)
2 users (show)

See Also:


Attachments
Proposed patch (2.36 KB, patch)
2014-11-07 07:50 PST, Xavier Claessens
no flags Details | Formatted Diff | Diff
patch (2.94 KB, patch)
2014-12-11 13:54 PST, Xavier Claessens
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Xavier Claessens 2014-11-05 08:54:05 PST
When hlsdemux downloads next fragments, it will change source's state from PAUSE to READY, then change its uri, and change state back from READY to PAUSE. That state change is catched in WebKitWebSourceGStreamer::webKitWebSrcChangeState(). That sequence of events can happen:

1) pause->ready state change, priv->stopID is set to an idle cb ID that will call webKitWebSrcStop in main thread.
2) ready->pause state change, priv->startID is set to an idle cb ID that will call webKitWebSrcStart in main thread.
3) the main thread runs webKitWebSrcStop() that calls removeTimeoutSources() which remove priv->startID source.
And now webKitWebSrcStart will never be called, so it won't download anything.

So that happens when webkitwebsrc's state transition pause->ready->pause quickly.
Comment 1 Xavier Claessens 2014-11-05 08:54:40 PST
Note that shen souphttpsrc is used, it works correctly.
Comment 2 Xavier Claessens 2014-11-07 07:50:14 PST
Created attachment 241179 [details]
Proposed patch

I'm not sure what's the procedure to properly propose patches, but this one fix the issue for me.
Comment 3 Philippe Normand 2014-11-18 08:41:41 PST
You can find the contributor guidelines there: http://www.webkit.org/coding/contributing.html
Comment 4 Xavier Claessens 2014-12-11 13:54:25 PST
Created attachment 243145 [details]
patch

Patch updated to latest webkit master, with changelog. Is that all needed to get it reviewed?
Comment 5 Philippe Normand 2014-12-15 07:02:15 PST
Comment on attachment 243145 [details]
patch

Thanks!
Comment 6 WebKit Commit Bot 2014-12-15 07:37:23 PST
Comment on attachment 243145 [details]
patch

Clearing flags on attachment: 243145

Committed r177279: <http://trac.webkit.org/changeset/177279>
Comment 7 WebKit Commit Bot 2014-12-15 07:37:26 PST
All reviewed patches have been landed.  Closing bug.