[FFmpeg-trac] #3194(avcodec:new): valgrind leak on example package

FFmpeg trac at avcodec.org
Tue Dec 10 11:39:56 CET 2013


#3194: valgrind  leak on example package
------------------------------------+-----------------------------------
             Reporter:  andreyv     |                    Owner:
                 Type:  defect      |                   Status:  new
             Priority:  normal      |                Component:  avcodec
              Version:  git-master  |               Resolution:
             Keywords:  leak        |               Blocked By:
             Blocking:              |  Reproduced by developer:  0
Analyzed by developer:  0           |
------------------------------------+-----------------------------------

Comment (by andreyv):

 I've tested with suggested arguments. However , it doesn't help to fix the
 leak

 ./configure --prefix=/home/andrey/ffmpeg_sources/ffmpeg_latest --extra-
 ldflags=-L/home/andrey/ffmpeg_build/lib
 --bindir=/home/andrey/ffmpeg_build/bin --extra-libs=-ldl --extra-
 cflags=-I/home/andrey/ffmpeg_build/include --enable-gpl --disable-vaapi
 --disable-iconv

 ==6788== 24 bytes in 1 blocks are still reachable in loss record 1 of 1
 ==6788==    at 0x402A420: memalign (in
 /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
 ==6788==    by 0x402A4DE: posix_memalign (in
 /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
 ==6788==    by 0x86816A7: av_malloc (mem.c:94)
 ==6788==    by 0x808CB22: video_decode_example (decoding_encoding.c:557)
 ==6788==    by 0x808CC3B: main (decoding_encoding.c:635)

 line 557 is
     if (avcodec_open2(c, codec, NULL) < 0) {
         fprintf(stderr, "Could not open codec\n");
         exit(1);
     }
 the leak comes from the av_malloc, it is inside the allocation from
 avcodec_open2

--
Ticket URL: <https://trac.ffmpeg.org/ticket/3194#comment:7>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list