mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-23 19:30:05 +00:00
avformat/id3v2: fix memleak with empty strings
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
b83d907780
commit
cc6a59d2b9
@ -422,7 +422,10 @@ static void read_comment(AVFormatContext *s, AVIOContext *pb, int taglen,
|
||||
return;
|
||||
}
|
||||
|
||||
if (dst && dst[0]) {
|
||||
if (dst && !*dst)
|
||||
av_freep(&dst);
|
||||
|
||||
if (dst) {
|
||||
key = (const char *) dst;
|
||||
dict_flags |= AV_DICT_DONT_STRDUP_KEY;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user