After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 795157 - API: gst_queue_array_peek_nth
API: gst_queue_array_peek_nth
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
unspecified
Other All
: Normal enhancement
: 1.15.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-04-11 13:40 UTC by Mathieu Duponchelle
Modified: 2018-04-13 22:18 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
API: gst_queue_array_peek_nth (4.81 KB, patch)
2018-04-11 13:40 UTC, Mathieu Duponchelle
none Details | Review
API: gst_queue_array_peek_nth (5.37 KB, patch)
2018-04-12 14:27 UTC, Mathieu Duponchelle
committed Details | Review

Description Mathieu Duponchelle 2018-04-11 13:40:53 UTC
Self-explanatory :)
Comment 1 Mathieu Duponchelle 2018-04-11 13:40:58 UTC
Created attachment 370792 [details] [review]
API: gst_queue_array_peek_nth
Comment 2 Tim-Philipp Müller 2018-04-11 13:58:17 UTC
Comment on attachment 370792 [details] [review]
API: gst_queue_array_peek_nth

Looks good to me. Small nitpicks:

- Function docs should perhaps also explicitly mention that the caller must check that the idx is valid, we don't handle out of bounds index access gracefully (but maybe we just should? Dunno.)

- run make update-exports to add the new API also to win32/common/libgstbase.def (while it still exists)
Comment 3 Sebastian Dröge (slomo) 2018-04-11 19:04:17 UTC
(In reply to Tim-Philipp Müller from comment #2)
> Comment on attachment 370792 [details] [review] [review]
> API: gst_queue_array_peek_nth
> 
> Looks good to me. Small nitpicks:
> 
> - Function docs should perhaps also explicitly mention that the caller must
> check that the idx is valid, we don't handle out of bounds index access
> gracefully (but maybe we just should? Dunno.)

g_return_val_if_fail() please
Comment 4 Mathieu Duponchelle 2018-04-12 14:27:38 UTC
Created attachment 370862 [details] [review]
API: gst_queue_array_peek_nth
Comment 5 Mathieu Duponchelle 2018-04-12 14:29:26 UTC
(In reply to Sebastian Dröge (slomo) from comment #3)
> g_return_val_if_fail() please

yes, that was already the case

(In reply to Tim-Philipp Müller from comment #2)
> Comment on attachment 370792 [details] [review] [review]
> - Function docs should perhaps also explicitly mention that the caller must
> check that the idx is valid, we don't handle out of bounds index access
> gracefully (but maybe we just should? Dunno.)

Updated the docs, we do handle out of bounds access as gracefully as we can already though :)

> 
> - run make update-exports to add the new API also to
> win32/common/libgstbase.def (while it still exists)

Done
Comment 6 Mathieu Duponchelle 2018-04-13 22:17:06 UTC
Attachment 370862 [details] pushed as 03e27aa - API: gst_queue_array_peek_nth