mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-25 16:48:11 +00:00
tsdemux: Refuse negative rates which we don't support yet
And remove a check which was done before
This commit is contained in:
parent
e4a0c4d509
commit
fd4fd13dc8
1 changed files with 5 additions and 4 deletions
|
@ -505,14 +505,15 @@ gst_ts_demux_do_seek (MpegTSBase * base, GstEvent * event)
|
||||||
gst_event_parse_seek (event, &rate, &format, &flags, &start_type, &start,
|
gst_event_parse_seek (event, &rate, &format, &flags, &start_type, &start,
|
||||||
&stop_type, &stop);
|
&stop_type, &stop);
|
||||||
|
|
||||||
if (format != GST_FORMAT_TIME) {
|
|
||||||
goto done;
|
|
||||||
}
|
|
||||||
|
|
||||||
GST_DEBUG ("seek event, rate: %f start: %" GST_TIME_FORMAT
|
GST_DEBUG ("seek event, rate: %f start: %" GST_TIME_FORMAT
|
||||||
" stop: %" GST_TIME_FORMAT, rate, GST_TIME_ARGS (start),
|
" stop: %" GST_TIME_FORMAT, rate, GST_TIME_ARGS (start),
|
||||||
GST_TIME_ARGS (stop));
|
GST_TIME_ARGS (stop));
|
||||||
|
|
||||||
|
if (rate <= 0.0) {
|
||||||
|
GST_WARNING ("Negative rate not supported");
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
if (flags & (GST_SEEK_FLAG_SEGMENT | GST_SEEK_FLAG_SKIP)) {
|
if (flags & (GST_SEEK_FLAG_SEGMENT | GST_SEEK_FLAG_SKIP)) {
|
||||||
GST_WARNING ("seek flags 0x%x are not supported", (int) flags);
|
GST_WARNING ("seek flags 0x%x are not supported", (int) flags);
|
||||||
goto done;
|
goto done;
|
||||||
|
|
Loading…
Reference in a new issue