After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 737739 - souphttpclientsink: Restarting after error results in buffers being queued forever
souphttpclientsink: Restarting after error results in buffers being queued fo...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
git master
Other Linux
: Normal normal
: 1.4.4
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-10-01 17:49 UTC by Nirbheek Chauhan
Modified: 2014-10-14 07:44 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Free queued buffers in reset (1.35 KB, patch)
2014-10-01 17:49 UTC, Nirbheek Chauhan
committed Details | Review
Add some useful debugging output (1.59 KB, patch)
2014-10-01 17:52 UTC, Nirbheek Chauhan
committed Details | Review

Description Nirbheek Chauhan 2014-10-01 17:49:59 UTC
Created attachment 287532 [details] [review]
Free queued buffers in reset

$subject, the problem seems to be that ::reset() doesn't drop buffers, and when the element is restarted, ::render() waits forever for the old buffers to be written out before scheduling a new callback to write out new buffers.

The attached patch fixes this.
Comment 1 Nirbheek Chauhan 2014-10-01 17:52:23 UTC
Created attachment 287533 [details] [review]
Add some useful debugging output

The attached patch adds some logging to cases where the code drops or queues buffers; useful while debugging issues, but not necessary. :)
Comment 2 Sebastian Dröge (slomo) 2014-10-02 06:49:25 UTC
commit 374552a72093fa74e7d99f5a02219ce6674ff611
Author: Nirbheek Chauhan <nirbheek@centricular.com>
Date:   Wed Oct 1 23:12:30 2014 +0530

    souphttpclientsink: Add some more useful debug logging

commit 745d49731810d774463e72b03e759092e2b2e8b7
Author: Nirbheek Chauhan <nirbheek@centricular.com>
Date:   Wed Oct 1 23:05:03 2014 +0530

    souphttpclientsink: Free queued buffers in ::reset
    
    ::render sets a new callback for writing out new buffers only if there aren't
    already buffers queued for writing with a previously-scheduled callback.
    However, if the previously-scheduled callback is interrupted by a state change
    (either manually or due to an error) and there are still buffers in the queue,
    restarting the pipeline will result in buffers being queued forever, and no
    callbacks will ever be scheduled, and no buffers will be written out.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=737739