[FFmpeg-trac] #8079(avcodec:new): s5p-mfc: v4l2_m2m segfaults when encoding

FFmpeg trac at avcodec.org
Thu Aug 15 04:42:05 EEST 2019

#8079: s5p-mfc: v4l2_m2m segfaults when encoding
             Reporter:  jasaw       |                    Owner:
                 Type:  defect      |                   Status:  new
             Priority:  normal      |                Component:  avcodec
              Version:  git-master  |               Resolution:
             Keywords:  v4l2m2m     |               Blocked By:
             Blocking:              |  Reproduced by developer:  0
Analyzed by developer:  0           |

Comment (by jasaw):

 From my quick investigation, it looks like this driver requires multi-
 planar buffers. FFmpeg (ff_v4l2_buffer_initialize function) is aware that
 it is dealing with multi-planar, so set the num_planes to 2. When the
 example code calls av_frame_get_buffer, it only allocates buffer for one
 plane and left the other plane buffer as NULL, which causes the segfault.

 Question is, how to get the example code to work?

Ticket URL: <https://trac.ffmpeg.org/ticket/8079#comment:4>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker

More information about the FFmpeg-trac mailing list