[FFmpeg-devel] [PATCH]lavf/matroskaenc: Do not write two CodecID elements for rawvideo
Michael Niedermayer
michaelni at gmx.at
Fri Jan 13 19:44:08 EET 2017
On Thu, Jan 12, 2017 at 03:01:03PM +0100, Carl Eugen Hoyos wrote:
> 2017-01-11 19:55 GMT+01:00 Michael Niedermayer <michael at niedermayer.cc>:
> > On Tue, Jan 10, 2017 at 05:23:04PM +0100, Carl Eugen Hoyos wrote:
> >> Hi!
> >>
> >> Attached patch fixes ticket #6068.
> >>
> >> Please comment, Carl Eugen
> >
> >> matroskaenc.c | 1 +
> >> 1 file changed, 1 insertion(+)
> >> 41a44b306b4f66f182c30289e093372556ca184c 0001-lavf-matroskaenc-Do-not-write-two-CodecID-elements-f.patch
> >> From b100ef83e257d8a106eefa3d2da9463ccd0e87d8 Mon Sep 17 00:00:00 2001
> >> From: Carl Eugen Hoyos <cehoyos at ag.or.at>
> >> Date: Tue, 10 Jan 2017 17:21:08 +0100
> >> Subject: [PATCH] lavf/matroskaenc: Do not write two CodecID elements for
> >> rawvideo.
> >>
> >> Fixes ticket #6068.
> >
> > breaks fate
>
> New patch attached.
>
> Thank you, Carl Eugen
> libavformat/matroskaenc.c | 1 +
> tests/ref/fate/rgb24-mkv | 4 ++--
> 2 files changed, 3 insertions(+), 2 deletions(-)
> ac6db46a99c6d14288d5dad0fb813b13f9c6fa28 0001-lavf-matroskaenc-Do-not-write-two-CodecID-elements-f.patch
> From 61fc1a71c0af73657b5260ea4e7a29d43e94c937 Mon Sep 17 00:00:00 2001
> From: Carl Eugen Hoyos <cehoyos at ag.or.at>
> Date: Thu, 12 Jan 2017 14:50:52 +0100
> Subject: [PATCH] lavf/matroskaenc: Do not write two CodecID elements for
> rawvideo.
>
> Fixes ticket #6068.
> ---
> libavformat/matroskaenc.c | 1 +
> tests/ref/fate/rgb24-mkv | 4 ++--
> 2 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
> index 78a621e..7e97586 100644
> --- a/libavformat/matroskaenc.c
> +++ b/libavformat/matroskaenc.c
> @@ -1119,6 +1119,7 @@ static int mkv_write_track(AVFormatContext *s, MatroskaMuxContext *mkv,
> } else {
> // look for a codec ID string specific to mkv to use,
> // if none are found, use AVI codes
> + if (par->codec_id != AV_CODEC_ID_RAWVIDEO || par->codec_tag)
> for (j = 0; ff_mkv_codec_tags[j].id != AV_CODEC_ID_NONE; j++) {
> if (ff_mkv_codec_tags[j].id == par->codec_id) {
> put_ebml_string(pb, MATROSKA_ID_CODECID, ff_mkv_codec_tags[j].str);
this would be simpler and more robust as a if/else
no more comments from me
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
If a bugfix only changes things apparently unrelated to the bug with no
further explanation, that is a good sign that the bugfix is wrong.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170113/e18d0a3b/attachment.sig>
More information about the ffmpeg-devel
mailing list