summaryrefslogtreecommitdiff
path: root/libavformat/matroskaenc.c
diff options
context:
space:
mode:
authorJohn Stebbins <stebbins@jetheaddev.com>2015-09-25 08:36:30 -0700
committerAnton Khirnov <anton@khirnov.net>2015-10-03 13:44:35 +0200
commitf56a08559334b7eb6b3fedbc0cc741887f6067ae (patch)
tree35c78fda6455f248817c3267d90dcff798ce923c /libavformat/matroskaenc.c
parent8bb376cf6b4ab8645daedb8becaa7163656436a4 (diff)
matroskaenc: Don't write a track language tag
"language" is not an offical matroska tag. Track languages are specified with the MATROSKA_ID_TRACKLANGUAGE ebml. Writing the tag overrides the ebml specified language during playback with libav and some other players. Signed-off-by: Anton Khirnov <anton@khirnov.net>
Diffstat (limited to 'libavformat/matroskaenc.c')
-rw-r--r--libavformat/matroskaenc.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
index db86e88557..2e4d277ae9 100644
--- a/libavformat/matroskaenc.c
+++ b/libavformat/matroskaenc.c
@@ -1005,7 +1005,9 @@ static int mkv_write_tag(AVFormatContext *s, AVDictionary *m, unsigned int eleme
while ((t = av_dict_get(m, "", t, AV_DICT_IGNORE_SUFFIX))) {
if (av_strcasecmp(t->key, "title") &&
- av_strcasecmp(t->key, "encoding_tool")) {
+ av_strcasecmp(t->key, "encoding_tool") &&
+ (elementid != MATROSKA_ID_TAGTARGETS_TRACKUID ||
+ av_strcasecmp(t->key, "language"))) {
ret = mkv_write_simpletag(s->pb, t);
if (ret < 0)
return ret;