Commit 26eb2940 authored by wm4's avatar wm4

avformat/hls: fix some cases of HLS streams which require cookies

Broken by commit ba12ba85. This only
happens with HLS streams which use encryption and require preserving
cookies sent by the server.

Fixes trac issue #4846.
parent a9509ad3
...@@ -516,15 +516,11 @@ static int url_connect(struct playlist *pls, AVDictionary *opts, AVDictionary *o ...@@ -516,15 +516,11 @@ static int url_connect(struct playlist *pls, AVDictionary *opts, AVDictionary *o
av_dict_copy(&tmp, opts, 0); av_dict_copy(&tmp, opts, 0);
av_dict_copy(&tmp, opts2, 0); av_dict_copy(&tmp, opts2, 0);
if ((ret = av_opt_set_dict(pls->input, &tmp)) < 0) if ((ret = ffurl_connect(pls->input, &tmp)) < 0) {
goto fail;
if ((ret = ffurl_connect(pls->input, NULL)) < 0) {
ffurl_close(pls->input); ffurl_close(pls->input);
pls->input = NULL; pls->input = NULL;
} }
fail:
av_dict_free(&tmp); av_dict_free(&tmp);
return ret; return ret;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment