openssl: set io_need always

When OpenSSL reports SSL_ERROR_WANT_READ, set the io_need explicitly.
It should have already been set by the BIO, but be safe.

Reported in Joshua's sarif data

Closes #18733
This commit is contained in:
Stefan Eissing 2025-09-25 13:31:17 +02:00 committed by Daniel Stenberg
parent 221b7dda38
commit 442943fb8e
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2

View file

@ -5369,6 +5369,7 @@ static CURLcode ossl_recv(struct Curl_cfilter *cf,
connclose(conn, "TLS close_notify");
break;
case SSL_ERROR_WANT_READ:
connssl->io_need = CURL_SSL_IO_NEED_RECV;
result = CURLE_AGAIN;
goto out;
case SSL_ERROR_WANT_WRITE: