Arm Mbed OS support forum

Why isn't mbedtls_ssl_set_bio() called again after reconnect?

I am looking at the ssl_client2.c example program

In the “reconnect” section, mbedtls_net_free(&server_fd) & mbedtls_net_connect(&server_fd, …) are called but mbedtls_ssl_set_bio( … , &server_fd, … ) is not called again.

Wouldn’t the mbedtls_net_connect() possibly create a new “server_fd”? Why doesn’t mbedtls_ssl_set_bio() need to be called again?