From: Matt Caswell Date: Mon, 16 Apr 2018 13:06:56 +0000 (+0100) Subject: Fix assertion failure in SSL_set_bio() X-Git-Tag: OpenSSL_1_1_0i~183 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1d015368ebe245c4468522d152edfd8a1069426e;p=openssl Fix assertion failure in SSL_set_bio() If SSL_set_bio() is called with a NULL wbio after a failed connection then this can trigger an assertion failure. This should be valid behaviour and the assertion is in fact invalid and can simply be removed. Reviewed-by: Viktor Dukhovni (Merged from https://github.com/openssl/openssl/pull/5966) (cherry picked from commit bd7775e14a19c326d3720f2345c2ae324409e979) --- diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 8a190d23e8..a1a514fcf2 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -3519,7 +3519,6 @@ void ssl_free_wbio_buffer(SSL *s) return; s->wbio = BIO_pop(s->wbio); - assert(s->wbio != NULL); BIO_free(s->bbio); s->bbio = NULL; }