TLS Stream: use ISC_R_CANCELLED error when shutting down

This commit changes ISC_R_NOTCONNECTED error code to ISC_R_CANCELLED
when attempting to start reading data on the shutting down socket in
order to make its behaviour compatible with that of TCP and not break
the common code in the unit tests.
This commit is contained in:
Artem Boldariev
2022-10-27 21:16:36 +03:00
parent fb9955a372
commit ef659365ce

View File

@@ -864,7 +864,7 @@ isc__nm_tls_read(isc_nmhandle_t *handle, isc_nm_recv_cb_t cb, void *cbarg) {
REQUIRE(sock->tid == isc_tid());
if (inactive(sock)) {
cb(handle, ISC_R_NOTCONNECTED, NULL, cbarg);
cb(handle, ISC_R_CANCELED, NULL, cbarg);
return;
}