hlsdemux: seems there was a typo, free the adapter if it contains data, not if already empty

This commit is contained in:
Youness Alaoui 2011-08-26 22:48:01 +00:00 committed by Sebastian Dröge
parent 4a6d888961
commit ed5a5cc139

View file

@ -642,7 +642,7 @@ gst_hls_demux_stop_fetcher_locked (GstHLSDemux * demux, gboolean cancelled)
demux->fetcher = NULL;
/* if we stopped it to cancell a download, free the cached buffer */
if (cancelled && !gst_adapter_available (demux->download)) {
if (cancelled && gst_adapter_available (demux->download)) {
gst_adapter_clear (demux->download);
}
/* signal the fetcher thread that the download has finished/cancelled */