summaryrefslogtreecommitdiffstats
path: root/ext/flac/gstflacdec.h
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim.muller@collabora.co.uk>2009-07-21 19:46:55 +0100
committerTim-Philipp Müller <tim.muller@collabora.co.uk>2009-07-21 19:58:04 +0100
commit375976c847b80ab40ff30e1e5cef91ff12bddf50 (patch)
tree509bfafb8ecae5193adabcc7001ae48f6e394cb8 /ext/flac/gstflacdec.h
parent89903987332864891691e511b8ef56022ac85ea4 (diff)
flacdec: fix intermittent FLAC__STREAM_DECODER_ABORTED errors when seeking
When seeking in a local flac file (ie. operating pull-based), the decoder would often just error out after the loop function sees a DECODER_ABORTED status. This, however, is the read callback's way of telling our loop function that pull_range failed and streaming should stop, in this case because of the flush-start event that the seek handler pushed upstream from the seeking thread. Handle this slightly better by storing the last flow return from pull_range, so the loop function can evaluate it properly when it encounters a DECODER_ABORTED and take the right action. Fixes #578612.
Diffstat (limited to 'ext/flac/gstflacdec.h')
-rw-r--r--ext/flac/gstflacdec.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/ext/flac/gstflacdec.h b/ext/flac/gstflacdec.h
index a9daf3e9..e6a76bbb 100644
--- a/ext/flac/gstflacdec.h
+++ b/ext/flac/gstflacdec.h
@@ -74,6 +74,8 @@ struct _GstFlacDec {
GstEvent *start_segment;
GstTagList *tags;
+ GstFlowReturn pull_flow; /* last flow from pull_range */ /* STREAM_LOCK */
+
GstFlowReturn last_flow; /* the last flow return received from either
* gst_pad_push or gst_pad_buffer_alloc */