1
0
mirror of https://github.com/coturn/coturn.git synced 2026-05-05 10:46:10 +02:00

fix: double free ssl crash

AFAIU Openssl 1.1 SSL_set0_rbio() calls BIO_free_ all automatically..
"On calling this function, any existing rbio that was previously set will also be freed via a call to BIO_free_all"
This commit is contained in:
Mészáros Mihály 2018-09-10 15:41:14 +02:00
parent 0173d72974
commit c8313ac68d

View File

@ -1920,10 +1920,9 @@ int ssl_read(evutil_socket_t fd, SSL* ssl, ioa_network_buffer_handle nbh, int ve
if(ret>0) {
ioa_network_buffer_add_offset_size(nbh, (u16bits)buf_size, 0, (size_t)ret);
}
BIO_free(rbio);
#if OPENSSL_VERSION_NUMBER < 0x10100000L
ssl->rbio = NULL;
BIO_free(rbio);
#else
SSL_set0_rbio(ssl,NULL);
#endif