[FFmpeg-cvslog] avconv: fix handling attachments in init_output_stream

Anton Khirnov git at videolan.org
Thu Aug 4 21:17:00 EEST 2016


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Mon May 23 09:59:35 2016 +0200| [5e1840622ce6e41c57d9c407604863d3f3dcc3ae] | committer: Anton Khirnov

avconv: fix handling attachments in init_output_stream

The current code assumes that encoding_needed is simply an inverse of
stream_copy, which is not true for manually attached files (for which
neither of those is true).

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=5e1840622ce6e41c57d9c407604863d3f3dcc3ae
---

 avconv.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/avconv.c b/avconv.c
index e5a76b1..4f8d688 100644
--- a/avconv.c
+++ b/avconv.c
@@ -1734,7 +1734,7 @@ static int init_output_stream(OutputStream *ost, char *error, int error_len)
         }
 
         ost->st->time_base = ost->enc_ctx->time_base;
-    } else {
+    } else if (ost->stream_copy) {
         ret = av_opt_set_dict(ost->enc_ctx, &ost->encoder_opts);
         if (ret < 0)
             return ret;



More information about the ffmpeg-cvslog mailing list