aboutsummaryrefslogtreecommitdiffstats
path: root/ffmpeg.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-12-24 13:04:26 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-12-24 13:04:26 +0000
commit18531e52331becf277cc16bab7eaecfe9cbac885 (patch)
treea2eb518bc9529254c4df709dd74403eeefdb0a8b /ffmpeg.c
parenta46a7052bc20b630dae19148584941ced5ae78d6 (diff)
downloadffmpeg-18531e52331becf277cc16bab7eaecfe9cbac885.tar.gz
fix segfault with -vcodec copy
Originally committed as revision 1360 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'ffmpeg.c')
-rw-r--r--ffmpeg.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ffmpeg.c b/ffmpeg.c
index 2fed0e8582..e0c7cb14b4 100644
--- a/ffmpeg.c
+++ b/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++;