mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2024-09-29 04:25:55 -04:00
Fix: Corrected response and fixed TLS for 416 Request Range Not Satisfiable responses
This commit is contained in:
parent
7c51a3aae7
commit
a0ab967fb9
@ -183,7 +183,7 @@ int client_read_bytes (client_t *client, void *buf, unsigned len)
|
|||||||
return bytes;
|
return bytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void client_send_error(client_t *client, int status, int plain, const char *message)
|
void client_send_error(client_t *client, int status, int plain, const char *message)
|
||||||
{
|
{
|
||||||
ssize_t ret;
|
ssize_t ret;
|
||||||
|
|
||||||
|
@ -80,5 +80,6 @@ int client_send_bytes (client_t *client, const void *buf, unsigned len);
|
|||||||
int client_read_bytes (client_t *client, void *buf, unsigned len);
|
int client_read_bytes (client_t *client, void *buf, unsigned len);
|
||||||
void client_set_queue (client_t *client, refbuf_t *refbuf);
|
void client_set_queue (client_t *client, refbuf_t *refbuf);
|
||||||
int client_check_source_auth (client_t *client, const char *mount);
|
int client_check_source_auth (client_t *client, const char *mount);
|
||||||
|
void client_send_error(client_t *client, int status, int plain, const char *message);
|
||||||
|
|
||||||
#endif /* __CLIENT_H__ */
|
#endif /* __CLIENT_H__ */
|
||||||
|
@ -625,10 +625,7 @@ int fserve_client_create (client_t *httpclient, const char *path)
|
|||||||
|
|
||||||
fail:
|
fail:
|
||||||
fclose (file);
|
fclose (file);
|
||||||
httpclient->respcode = 416;
|
client_send_error(httpclient, 416, 1, "Request Range Not Satisfiable\r\n");
|
||||||
sock_write (httpclient->con->sock,
|
|
||||||
"HTTP/1.0 416 Request Range Not Satisfiable\r\n\r\n");
|
|
||||||
client_destroy (httpclient);
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user