Commit ce921f1e authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

http: tighten redirection to the MMS module (fixes #19657)

Match the exact same "logic" as in previous VLC versions, i.e. only
if the Pragma header is exactly equal to "features", rather than
contains the "features" token.
parent 7a9b5249
......@@ -256,7 +256,8 @@ char *vlc_http_res_get_redirect(struct vlc_http_resource *restrict res)
char *url;
/* HACK: Seems like an MMS server. Redirect to MMSH scheme. */
if (vlc_http_msg_get_token(res->response, "Pragma", "features") != NULL
const char *pragma = vlc_http_msg_get_header(res->response, "Pragma");
if (pragma != NULL && !vlc_ascii_strcasecmp(pragma, "features")
&& asprintf(&url, "mmsh://%s%s", res->authority, res->path) >= 0)
return url;
......
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