Commit 91d08e51 authored by Francois Cartegnie's avatar Francois Cartegnie

sout: chromecast: close tls connection on error

parent 8b38a343
......@@ -325,6 +325,7 @@ static void Close(vlc_object_t *p_this)
sendMessages(p_stream);
// ft
case CHROMECAST_TLS_CONNECTED:
case CHROMECAST_CONNECTION_DEAD:
disconnectChromecast(p_stream);
p_sys->i_status = CHROMECAST_DISCONNECTED;
// ft
......@@ -388,8 +389,12 @@ static void disconnectChromecast(sout_stream_t *p_stream)
{
sout_stream_sys_t *p_sys = p_stream->p_sys;
vlc_tls_SessionDelete(p_sys->p_tls);
vlc_tls_Delete(p_sys->p_creds);
if (p_sys->p_tls)
{
vlc_tls_SessionDelete(p_sys->p_tls);
vlc_tls_Delete(p_sys->p_creds);
p_sys->p_tls = NULL;
}
}
......
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