Skip to content
Snippets Groups Projects
Commit 7f59577f authored by Tatsuhiro Tsujikawa's avatar Tatsuhiro Tsujikawa Committed by Yang Tse
Browse files

Metalink: ignore --include if --metalink is used.

Including headers in response body will break Metalink XML parser.
If it is included in the file described in Metalink XML, hash check
will fail. Therefore, --include should be ignored if --metalink is
used.
parent b193ba8a
No related branches found
No related tags found
No related merge requests found
......@@ -879,7 +879,10 @@ int operate(struct Configurable *config, int argc, argv_item_t argv[])
my_setopt(curl, CURLOPT_NOBODY, 1);
my_setopt(curl, CURLOPT_HEADER, 1);
}
else
/* If --metalink is used, we ignore --include (headers in
output) option because mixing headers to the body will
confuse XML parser and/or hash check will fail. */
else if(!config->use_metalink)
my_setopt(curl, CURLOPT_HEADER, config->include_headers);
#if !defined(CURL_DISABLE_PROXY)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment