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 788500 - [libav] [Memory Leak] Memory not freed in failure case in function parse_vtrk
[libav] [Memory Leak] Memory not freed in failure case in function parse_vtrk
Status: RESOLVED NOTGNOME
Product: GStreamer
Classification: Platform
Component: gst-libav
1.12.3
Other All
: Normal minor
: NONE
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-10-04 09:23 UTC by Ashish Kumar
Modified: 2017-10-04 09:52 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Ashish Kumar 2017-10-04 09:23:42 UTC
Possible memory leak is as below:-
File: 4xm.c : Line No. 117
Function: static int parse_vtrk(AVFormatContext *s,
                      FourxmDemuxContext *fourxm, uint8_t *buf, int size,
                      int left)

...
st = avformat_new_stream(s, NULL);

...

st not freed in case of failure i.e.

return AVERROR(ENOMEM);


Solution:-

av_free(st);
Comment 1 Tim-Philipp Müller 2017-10-04 09:52:44 UTC
Thanks for the bug report, but this is something that should be submitted to the ffmpeg/libav projects. We don't patch our internal copy of ffmpeg.