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 693704 - gst_message_parse_{warning,error} annotations wrongly claim allow-none for GError parameter
gst_message_parse_{warning,error} annotations wrongly claim allow-none for GE...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
1.x
Other Linux
: Normal normal
: 1.0.6
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-02-13 14:16 UTC by Jens Georg
Modified: 2013-02-13 16:54 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jens Georg 2013-02-13 14:16:12 UTC
The docs/annotations claim that it's possible to pass NULL for the GError ** parameter but that happily crashes; looking at the code, *gerror is assigned without checking. So either the docs are wrong or the code is.
Comment 1 Jens Georg 2013-02-13 14:17:44 UTC
Same for gst_message_parse_warning, obviously
Comment 2 Jens Georg 2013-02-13 14:20:35 UTC
also applies to 0.10 if you care.
Comment 3 Tim-Philipp Müller 2013-02-13 16:45:47 UTC
Thanks, nice catch. I think they should accept NULL pointers even if it's not every useful in this case, for consistency.
Comment 4 Tim-Philipp Müller 2013-02-13 16:54:50 UTC
commit 5fc34add2560ad3d6abd970b0b8cbe4f35e00f2a
Author: Tim-Philipp Müller <tim.muller@collabora.co.uk>
Date:   Wed Feb 13 16:52:13 2013 +0000

    message: accept NULL error argument in gst_message_parse_{error,warning,info}
    
    And simplify code a bit while at it.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=693704