mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-03-28 12:32:17 +02:00
lavf/id3v2: do not export empty fields.
This also avoids a memleak.
This commit is contained in:
parent
4fd573970a
commit
6ad974ae1c
@ -303,6 +303,8 @@ static void read_ttag(AVFormatContext *s, AVIOContext *pb, int taglen, const cha
|
|||||||
}
|
}
|
||||||
else if (*dst)
|
else if (*dst)
|
||||||
dict_flags |= AV_DICT_DONT_STRDUP_VAL;
|
dict_flags |= AV_DICT_DONT_STRDUP_VAL;
|
||||||
|
else
|
||||||
|
av_freep(&dst);
|
||||||
|
|
||||||
if (dst)
|
if (dst)
|
||||||
av_dict_set(&s->metadata, key, dst, dict_flags);
|
av_dict_set(&s->metadata, key, dst, dict_flags);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user