asfdec: do not export empty metadata
Signed-off-by: Anton Khirnov <anton@khirnov.net>
This commit is contained in:
parent
3e853ff7ac
commit
78491fe8cf
@ -256,8 +256,10 @@ static int asf_read_metadata(AVFormatContext *s, const char *title, uint16_t len
|
|||||||
AVIOContext *pb = s->pb;
|
AVIOContext *pb = s->pb;
|
||||||
|
|
||||||
avio_get_str16le(pb, len, ch, buflen);
|
avio_get_str16le(pb, len, ch, buflen);
|
||||||
|
if (ch[0]) {
|
||||||
if (av_dict_set(&s->metadata, title, ch, 0) < 0)
|
if (av_dict_set(&s->metadata, title, ch, 0) < 0)
|
||||||
av_log(s, AV_LOG_WARNING, "av_dict_set failed.\n");
|
av_log(s, AV_LOG_WARNING, "av_dict_set failed.\n");
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user