[FFmpeg-trac] #8253(undetermined:new): Segmentation fault in av_frame_ref at libavutil/frame.c:453

FFmpeg trac at avcodec.org
Fri Oct 11 08:36:13 EEST 2019

#8253: Segmentation fault in av_frame_ref at libavutil/frame.c:453
             Reporter:  Suhwan       |                     Type:  defect
               Status:  new          |                 Priority:  normal
            Component:               |                  Version:  git-
  undetermined                       |  master
             Keywords:               |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
 Summary of the bug:
 There is a Segmentation fault in av_frame_ref at libavutil/frame.c:453
 Thread 1 "ffmpeg_g" received signal SIGSEGV, Segmentation fault.
 av_frame_ref (dst=0x24153c0, src=0x0) at libavutil/frame.c:453
 453         dst->channels       = src->channels;
 (gdb) bt
 #0  av_frame_ref (dst=0x24153c0, src=0x0) at libavutil/frame.c:453
 #1  0x00000000013d4f0d in av_frame_clone (src=0x0) at
 #2  0x00000000004b3b66 in request_frame (outlink=<optimized out>) at
 #3  0x0000000000452f92 in ff_request_frame_to_filter (link=0x2307600) at
 #4  0x0000000000451e55 in forward_status_change (filter=<optimized out>,
 in=<optimized out>)
     at libavfilter/avfilter.c:1243
 #5  ff_filter_activate_default (filter=<optimized out>) at
 #6  ff_filter_activate (filter=0x23054c0) at libavfilter/avfilter.c:1430
 #7  0x000000000045777c in push_frame (graph=0x22e2900) at
 #8  av_buffersrc_close (ctx=<optimized out>, pts=<optimized out>, flags=4)
     at libavfilter/buffersrc.c:275
 #9  0x000000000041f8a7 in ifilter_send_eof (ifilter=0x1ffffffff,
 pts=<optimized out>)
     at fftools/ffmpeg.c:2213
 #10 send_filter_eof (ist=<optimized out>) at fftools/ffmpeg.c:2562
 #11 process_input_packet (ist=<optimized out>, pkt=<optimized out>,
 no_eof=<optimized out>)
     at fftools/ffmpeg.c:2701
 #12 0x000000000041c465 in process_input (file_index=<optimized out>) at
 #13 transcode_step () at fftools/ffmpeg.c:4638
 #14 transcode () at fftools/ffmpeg.c:4692
 #15 0x0000000000419377 in main (argc=<optimized out>, argv=<optimized
 out>) at fftools/ffmpeg.c:4894
 (gdb) list
 448         av_assert1(dst->channels == 0);
 450         dst->format         = src->format;
 451         dst->width          = src->width;
 452         dst->height         = src->height;
 453         dst->channels       = src->channels;
 454         dst->channel_layout = src->channel_layout;
 455         dst->nb_samples     = src->nb_samples;
 457         ret = frame_copy_props(dst, src, 0);
 (gdb) print src
 $1 = (const AVFrame *) 0x0
 (gdb) disass $pc-32,$pc+32
 Dump of assembler code from 0x13d441e to 0x13d445e:
    0x00000000013d441e <av_frame_get_buffer+942>:        pop    %rsi
    0x00000000013d441f <av_frame_get_buffer+943>:        pop    %r15
    0x00000000013d4421 <av_frame_get_buffer+945>:        pop    %rbp
    0x00000000013d4422 <av_frame_get_buffer+946>:        retq
    0x00000000013d4423:  data16 data16 data16 nopw %cs:0x0(%rax,%rax,1)
    0x00000000013d4430 <av_frame_ref+0>: push   %rbp
    0x00000000013d4431 <av_frame_ref+1>: push   %r15
    0x00000000013d4433 <av_frame_ref+3>: push   %r14
    0x00000000013d4435 <av_frame_ref+5>: push   %r12
    0x00000000013d4437 <av_frame_ref+7>: push   %rbx
    0x00000000013d4438 <av_frame_ref+8>: mov    %rsi,%rbp
    0x00000000013d443b <av_frame_ref+11>:        mov    %rdi,%r12
 => 0x00000000013d443e <av_frame_ref+14>:        mov    0x1bc(%rbp),%eax
    0x00000000013d4444 <av_frame_ref+20>:        mov    %eax,0x1bc(%r12)
    0x00000000013d444c <av_frame_ref+28>:        mov    0x118(%rbp),%rax
    0x00000000013d4453 <av_frame_ref+35>:        mov    %rax,0x118(%r12)
    0x00000000013d445b <av_frame_ref+43>:        movups 0x68(%rbp),%xmm0
 End of assembler dump.

 How to reproduce:
 % ffmpeg_g -y -r 0 -i $PoC1 -i $PoC2 -filter_complex deflicker -target dvd
 -loglevel 99 -vbsf mpeg2_metadata tmp.tta

 ffmpeg version N-95314-g1331e00179 Copyright (c) 2000-2019 the FFmpeg
   built with clang version 6.0.0-1ubuntu2 (tags/RELEASE_600/final)
   configuration: --cc=clang --cxx=clang++ --ld=clang --enable-debug

Ticket URL: <https://trac.ffmpeg.org/ticket/8253>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker

More information about the FFmpeg-trac mailing list