diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2015-09-05 14:21:47 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2015-09-05 14:28:08 +0200 |
commit | 4eca1939ef0614d0959fffb93f93d44af6740e8c (patch) | |
tree | f4c3cf3e6805a77ebbc0e403733210daaf653da6 | |
parent | c41a59330f49c16acfa9b0552608fa1f41a0d823 (diff) | |
download | ffmpeg-4eca1939ef0614d0959fffb93f93d44af6740e8c.tar.gz |
avformat/hls: Check for av_opt_set_dict() failure
Fixes: CID1320426
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavformat/hls.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavformat/hls.c b/libavformat/hls.c index 82dd744983..c16c7708f4 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -516,13 +516,15 @@ static int url_connect(struct playlist *pls, AVDictionary *opts, AVDictionary *o av_dict_copy(&tmp, opts, 0); av_dict_copy(&tmp, opts2, 0); - av_opt_set_dict(pls->input, &tmp); + if ((ret = av_opt_set_dict(pls->input, &tmp)) < 0) + goto fail; if ((ret = ffurl_connect(pls->input, NULL)) < 0) { ffurl_close(pls->input); pls->input = NULL; } +fail: av_dict_free(&tmp); return ret; } |