[Bug 796559] qtdemux: Various segment fixes to properly take segment.offset into account

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Jun 20 08:22:12 UTC 2018


https://bugzilla.gnome.org/show_bug.cgi?id=796559

--- Comment #22 from Edward Hervey <bilboed at bilboed.com> ---
Review of attachment 372723:
 --> (https://bugzilla.gnome.org/review?bug=796559&attachment=372723)

::: gst/gstelement.c
@@ +1897,3 @@
       gst_event_new_seek (rate, format, flags, start_type, start, stop_type,
       stop);
+  g_return_val_if_fail (GST_IS_EVENT (event), FALSE);

That should just be a regular "if (event) return FALSE;"

g_return* functions should only be used for inputs. And you will already have
an assert triggered in gst_event_new_seek()

::: gst/gstevent.c
@@ +1267,3 @@
   g_return_val_if_fail (rate != 0.0, NULL);
+  if (rate > 0)
+    g_return_val_if_fail (GST_CLOCK_TIME_IS_VALID (start) ||

start is a 'gint64'

If you do a (GST_FORMAT_BYTES, SEEK_TYPE_END, -1) (i.e. the end position in
bytes minus 1) it is valid.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list