Commit 6e7c65bc authored by Philipp Schafft's avatar Philipp Schafft 🦁

send Expires:-headers on all cache=0 requests, close #1870

svn path=/icecast/trunk/icecast/; revision=18805
parent d0bf2c64
......@@ -679,10 +679,6 @@ static int format_mp3_create_client_data(source_t *source, client_t *client)
bytes = snprintf (ptr, remaining, "Content-Length: 221183499\r\n");
remaining -= bytes;
ptr += bytes;
/* avoid browser caching, reported via forum */
bytes = snprintf (ptr, remaining, "Expires: Mon, 26 Jul 1997 05:00:00 GMT\r\n");
remaining -= bytes;
ptr += bytes;
}
client->format_data = client_mp3;
......
......@@ -569,7 +569,9 @@ ssize_t util_http_build_header(char * out, size_t len, ssize_t offset,
currenttime_buffer,
contenttype_buffer,
(status == 401 ? "WWW-Authenticate: Basic realm=\"Icecast2 Server\"\r\n" : ""),
(cache ? "" : "Cache-Control: no-cache\r\n"),
(cache ? "" : "Cache-Control: no-cache\r\n"
"Expires: Mon, 26 Jul 1997 05:00:00 GMT\r\n"
"Pragma: no-cache\r\n"),
(datablock ? "\r\n" : ""),
(datablock ? datablock : ""));
config_release_config();
......
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