[Bug 764707] segment: Modifiy inside segment condition

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Fri Apr 15 14:37:52 UTC 2016


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

--- Comment #10 from Seungha Yang <sh.yang at lge.com> ---
(In reply to Sebastian Dröge (slomo) from comment #7)
> Review of attachment 326089 [details] [review]:
> 
> ::: tests/check/gst/gstsegment.c
> @@ +358,3 @@
> +  /* touching boundary point. it's inside because stop at segment start */
> +  res = gst_segment_clip (&segment, GST_FORMAT_BYTES,
> +      100, 200, &cstart, &cstop);
> 
> stop is exclusive, so this should return FALSE

Code is changed that return FALSE

> 
> @@ +388,3 @@
> +
> +  /* start on boundary point */
> +  res = gst_segment_clip (&segment, GST_FORMAT_BYTES, 200, -1, &cstart,
> &cstop);
> 
> Maybe also some with stop!=-1 here?

Add test case with stop != -1
+  /* touching boundary point. it's inside because start at segment start */
+  res = gst_segment_clip (&segment, GST_FORMAT_BYTES,
+      200, 300, &cstart, &cstop);
+  fail_unless (res == TRUE);
+  fail_unless (cstart == 200);
+  fail_unless (cstop == 200);

-- 
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