[Bug 755161] h264parse: initialize slice group id earlier

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Thu Sep 17 08:24:23 PDT 2015


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

--- Comment #8 from sreerenj <bsreerenj at gmail.com> ---
(In reply to Sebastian Dröge (slomo) from comment #7)
> (In reply to Víctor Manuel Jáquez Leal from comment #6)
> > (In reply to Sebastian Dröge (slomo) from comment #5)
> > > Why exactly is that crashing though, shouldn't the struct be initialized
> > > with zeroes or something sensible before passing it there? 
> > 
> > That's the question, and in bug 754845 we discussed it. 
> > 
> > But, as the pointer is set to NULL in the function already, it seems to me
> > logical that the pointer should be set to NULL before the function could
> > return, so the a future call to gst_h264_pps_clear() doesn't crash.
> 
> Maybe to prevent such bugs in the future, we should memset() the structs to
> zero before parsing? For PPS/SPS/etc.

yes, do the memset + initialize the non zero default values...

> Otherwise someone might add another pointer field at some point, and then it
> crashes in the future again :)

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