diff --git a/ports/raspberrypi/common-hal/ssl/SSLSocket.c b/ports/raspberrypi/common-hal/ssl/SSLSocket.c index 4d6148a390..69ebcffb7e 100644 --- a/ports/raspberrypi/common-hal/ssl/SSLSocket.c +++ b/ports/raspberrypi/common-hal/ssl/SSLSocket.c @@ -267,6 +267,7 @@ bool common_hal_ssl_sslsocket_bind(ssl_sslsocket_obj_t *self, const char *host, void common_hal_ssl_sslsocket_close(ssl_sslsocket_obj_t *self) { self->closed = true; + common_hal_socketpool_socket_close(self->sock); mbedtls_pk_free(&self->pkey); mbedtls_x509_crt_free(&self->cert); mbedtls_x509_crt_free(&self->cacert);