mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2024-09-22 04:15:54 -04:00
Update: Changed set of default headers.
Two changes have been made. Both are HTTP/1.1 related changes and are purly meant for HTTP/1.1 clients that do not correctly support HTTP/1.0. * Added 'Connection: Close'. * Added 'no-store' to 'Cache-Control:'.
This commit is contained in:
parent
3da438a8da
commit
647c29e061
@ -638,13 +638,13 @@ ssize_t util_http_build_header(char * out, size_t len, ssize_t offset,
|
|||||||
|
|
||||||
config = config_get_config();
|
config = config_get_config();
|
||||||
extra_headers = _build_headers(status, config, source);
|
extra_headers = _build_headers(status, config, source);
|
||||||
ret = snprintf (out, len, "%sServer: %s\r\n%s%s%s%s%s%s%s",
|
ret = snprintf (out, len, "%sServer: %s\r\nConnection: Close\r\n%s%s%s%s%s%s%s",
|
||||||
status_buffer,
|
status_buffer,
|
||||||
config->server_id,
|
config->server_id,
|
||||||
currenttime_buffer,
|
currenttime_buffer,
|
||||||
contenttype_buffer,
|
contenttype_buffer,
|
||||||
(status == 401 ? "WWW-Authenticate: Basic realm=\"Icecast2 Server\"\r\n" : ""),
|
(status == 401 ? "WWW-Authenticate: Basic realm=\"Icecast2 Server\"\r\n" : ""),
|
||||||
(cache ? "" : "Cache-Control: no-cache\r\n"
|
(cache ? "" : "Cache-Control: no-cache, no-store\r\n"
|
||||||
"Expires: Mon, 26 Jul 1997 05:00:00 GMT\r\n"
|
"Expires: Mon, 26 Jul 1997 05:00:00 GMT\r\n"
|
||||||
"Pragma: no-cache\r\n"),
|
"Pragma: no-cache\r\n"),
|
||||||
extra_headers,
|
extra_headers,
|
||||||
|
Loading…
Reference in New Issue
Block a user