[Bug 753306] h264parser: fix MVC specific data memory leak

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Aug 5 21:38:45 PDT 2015


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

--- Comment #4 from Vineeth <vineeth.tm at samsung.com> ---
gst_h264_parser_parse_subset_sps() gets the extra MVC info into nalparser
variable
That is where the copying happens
gst_h264_sps_copy (&nalparser->sps[sps->id], sps);


so whats happening here is, first MVC data is parsed into sps.
And then it is being copied into nalparser->sps[]
now the sps being passed to gst_h264_parser_parse_subset_sps() is a local
variable.
GstH264SPS sps = { 0, }
which will be not valid as soon as the function exits.. so the memory allocated
for sps will be leaked..


If not clear in codecparser, it should be freed in h264parse

so it will be something like
pres = gst_h264_parser_parse_subset_sps (nalparser, nalu, &sps, TRUE);
gst_h264_sps_clear (&sps);



This is the right fix? I added it in codecparsers, to make sure whoever uses it
will not need to do it 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