1
0
mirror of https://gitlab.xiph.org/xiph/icecast-server.git synced 2024-11-03 04:17:17 -05:00

Fix: Detect socket errors on TLS based source connections

This commit is contained in:
Philipp Schafft 2015-02-07 12:21:31 +00:00
parent 7bc7472972
commit 765ceabe81

View File

@ -508,6 +508,10 @@ static refbuf_t *get_next_buffer (source_t *source)
} }
source->last_read = current; source->last_read = current;
refbuf = source->format->get_buffer (source); refbuf = source->format->get_buffer (source);
#ifdef HAVE_OPENSSL
if (source->client->con->ssl && (SSL_get_shutdown(source->client->con->ssl) & SSL_RECEIVED_SHUTDOWN))
source->client->con->error = 1;
#endif
if (source->client->con && source->client->con->error) if (source->client->con && source->client->con->error)
{ {
ICECAST_LOG_INFO("End of Stream %s", source->mount); ICECAST_LOG_INFO("End of Stream %s", source->mount);