oggdemux: Allow EOS on timestamp equal to stop/start

Changed the check to a current_time equal to the stop will produce
EOS instead of the next one. Also, segment.start can't be NONE, so removing
this check.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=696899
This commit is contained in:
Nicolas Dufresne 2013-03-30 11:00:35 +00:00 committed by Wim Taymans
parent 0940dae793
commit e58f838ca3

View file

@ -707,9 +707,8 @@ gst_ogg_demux_chain_peer (GstOggPad * pad, ogg_packet * packet,
/* check stream eos */
if ((ogg->segment.rate > 0.0 && ogg->segment.stop != GST_CLOCK_TIME_NONE &&
current_time > ogg->segment.stop) ||
(ogg->segment.rate < 0.0 && ogg->segment.start != GST_CLOCK_TIME_NONE &&
current_time < ogg->segment.start)) {
current_time >= ogg->segment.stop) ||
(ogg->segment.rate < 0.0 && current_time <= ogg->segment.start)) {
GST_DEBUG_OBJECT (ogg, "marking pad %p EOS", pad);
pad->is_eos = TRUE;
}