mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-14 19:25:01 +00:00
fix segfault with -vcodec copy
Originally committed as revision 1360 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
a46a7052bc
commit
18531e5233
7
ffmpeg.c
7
ffmpeg.c
@ -1400,8 +1400,15 @@ static int av_encode(AVFormatContext **output_files,
|
||||
av_abort();
|
||||
}
|
||||
} else {
|
||||
AVFrame avframe;
|
||||
|
||||
/* no reencoding needed : output the packet directly */
|
||||
/* force the input stream PTS */
|
||||
|
||||
//XXX/FIXME set keyframe flag from demuxer (or optionally from decoder)
|
||||
memset(&avframe, 0, sizeof(AVFrame));
|
||||
ost->st->codec.coded_frame= &avframe;
|
||||
|
||||
av_write_frame(os, ost->index, data_buf, data_size);
|
||||
ost->st->codec.frame_number++;
|
||||
ost->frame_number++;
|
||||
|
Loading…
Reference in New Issue
Block a user