mirror of
https://github.com/curl/curl.git
synced 2026-07-16 08:17:16 +03:00
wolfssl: when SSL_read() returns zero, check the error
Returning zero indicates end of connection, so if there's no data read but the connection is alive, it needs to return -1 with CURLE_AGAIN. Closes #8431
This commit is contained in:
parent
96f85a0fef
commit
327ef30530
1 changed files with 1 additions and 1 deletions
|
|
@ -917,7 +917,7 @@ static ssize_t wolfssl_recv(struct Curl_easy *data,
|
|||
|
||||
nread = SSL_read(backend->handle, buf, buffsize);
|
||||
|
||||
if(nread < 0) {
|
||||
if(nread <= 0) {
|
||||
int err = SSL_get_error(backend->handle, nread);
|
||||
|
||||
switch(err) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue