mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-29 10:52:20 +00:00
lavc/libkvazaar: fix memory leak after av_dict_parse_string fail
In case of failure, all the successfully set entries are stored in *pm. We need to manually free the created dictionary to avoid memory leak. Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
This commit is contained in:
parent
0099f71502
commit
cf9c9a9db9
@ -110,8 +110,8 @@ static av_cold int libkvazaar_init(AVCodecContext *avctx)
|
||||
entry->key, entry->value);
|
||||
}
|
||||
}
|
||||
av_dict_free(&dict);
|
||||
}
|
||||
av_dict_free(&dict);
|
||||
}
|
||||
|
||||
ctx->encoder = enc = api->encoder_open(cfg);
|
||||
|
Loading…
Reference in New Issue
Block a user