[FFmpeg-devel] [PATCH v2] libavformat/mxfdec: export user comments metadata

Mark Reid mindmark at gmail.com
Sun Mar 15 22:46:57 CET 2015


On Sun, Mar 15, 2015 at 1:59 PM, James Almer <jamrial at gmail.com> wrote:

> On 13/03/15 10:58 PM, Mark Reid wrote:
> > ---
> >  libavformat/mxf.h    |  1 +
> >  libavformat/mxfdec.c | 94
> +++++++++++++++++++++++++++++++++++++++++++++++++---
> >  2 files changed, 91 insertions(+), 4 deletions(-)
>
> From fate-mxf-missing-index-demux using valgrind
>
> ==6422==
> ==6422== HEAP SUMMARY:
> ==6422==     in use at exit: 128 bytes in 3 blocks
> ==6422==   total heap usage: 481 allocs, 478 frees, 276,837 bytes allocated
> ==6422==
> ==6422== 48 bytes in 1 blocks are definitely lost in loss record 3 of 3
> ==6422==    at 0x4C2C526: memalign (in
> /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
> ==6422==    by 0x4C2C641: posix_memalign (in
> /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
> ==6422==    by 0xD454CF: av_malloc (mem.c:95)
> ==6422==    by 0xD454CF: av_mallocz (mem.c:252)
> ==6422==    by 0xD454CF: av_calloc (mem.c:262)
> ==6422==    by 0x5CA3B7: mxf_read_strong_ref_array (mxfdec.c:693)
> ==6422==    by 0x5CA3B7: mxf_read_package (mxfdec.c:874)
> ==6422==    by 0x5CD352: mxf_read_local_tags (mxfdec.c:2292)
> ==6422==    by 0x5CD352: mxf_parse_klv (mxfdec.c:2340)
> ==6422==    by 0x5CD352: mxf_read_header (mxfdec.c:2735)
> ==6422==    by 0x639701: avformat_open_input (utils.c:466)
> ==6422==    by 0x476B14: open_input_file (ffmpeg_opt.c:890)
> ==6422==    by 0x477F77: open_files (ffmpeg_opt.c:2733)
> ==6422==    by 0x477F77: ffmpeg_parse_options (ffmpeg_opt.c:2770)
> ==6422==    by 0x468E46: main (ffmpeg.c:4010)
> ==6422==
> {
>
>
Forgot to free MXFPackage->comment_refs, attached patch should fix memory
leak
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-libavformat-mxfdec-fix-MXFPackage-comment_refs-memor.patch
Type: application/octet-stream
Size: 806 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150315/d561dda5/attachment.obj>


More information about the ffmpeg-devel mailing list