From 745d49731810d774463e72b03e759092e2b2e8b7 Mon Sep 17 00:00:00 2001 From: Nirbheek Chauhan Date: Wed, 1 Oct 2014 23:05:03 +0530 Subject: [PATCH] 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 --- ext/soup/gstsouphttpclientsink.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ext/soup/gstsouphttpclientsink.c b/ext/soup/gstsouphttpclientsink.c index 904d71c4c2..a1bfa1b74b 100644 --- a/ext/soup/gstsouphttpclientsink.c +++ b/ext/soup/gstsouphttpclientsink.c @@ -244,6 +244,9 @@ gst_soup_http_client_sink_init (GstSoupHttpClientSink * souphttpsink) static void gst_soup_http_client_sink_reset (GstSoupHttpClientSink * souphttpsink) { + g_list_free_full (souphttpsink->queued_buffers, + (GDestroyNotify) gst_buffer_unref); + souphttpsink->queued_buffers = NULL; g_free (souphttpsink->reason_phrase); souphttpsink->reason_phrase = NULL; souphttpsink->status_code = 0;