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 590856 - [decodebin2] triggers assertion failure on NULL caps
[decodebin2] triggers assertion failure on NULL caps
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Linux
: Normal normal
: 0.10.25
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2009-08-05 14:08 UTC by Mark Nauwelaerts
Modified: 2009-08-12 11:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Possible fix (1.63 KB, patch)
2009-08-05 14:10 UTC, Mark Nauwelaerts
committed Details | Review

Description Mark Nauwelaerts 2009-08-05 14:08:44 UTC
When analyzing new pads, NULL or empty caps are treated as unknown/unhandled caps.  However, gst_pb_utils_get_decoder_description does not appreciate NULL caps, and the corresponding missing decoder message for NULL caps may also be a bit off.
Comment 1 Mark Nauwelaerts 2009-08-05 14:10:14 UTC
Created attachment 139943 [details] [review]
Possible fix

Avoid assertion failure on NULL caps, and provide alternative message.

[Do not know if there is a case where NULL or empty should be considered as "not yet known" and therefore sent down the delayed path, though probably not]
Comment 2 Sebastian Dröge (slomo) 2009-08-08 20:59:00 UTC
IMHO that patch is correct but OTOH pads here should not have empty caps either. I guess the patch can be committed but what elements provided pads with empty caps here?
Comment 3 Mark Nauwelaerts 2009-08-08 21:20:08 UTC
This can happen if a _get_caps tries to provide caps that are a not a subset of template caps (e.g. width or height out or template range).  That is pretty unusual in itself, but this already has warnings of its own (and there may be other cases).
Comment 4 Tim-Philipp Müller 2009-08-08 22:58:29 UTC
Also (nitpicking), shouldn't the ("Stream caps %" GST_PTR_FORMAT, caps) in the else case where we know caps is NULL read something else?
Comment 5 Mark Nauwelaerts 2009-08-09 12:51:12 UTC
GST_PTR_FORMAT should properly handle a NULL pointer, with a sufficiently meaningful message as a result, though taste may vary here (or maybe more can/should be said?)
Comment 6 Mark Nauwelaerts 2009-08-12 11:41:49 UTC
commit 188d69844911491323385a7d5b1833778286aac0
Author: Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
Date:   Wed Aug 5 15:36:30 2009 +0200

    decodebin2: avoid assertion failure on empty/NULL caps