diff options
author | Daniel Stenberg <daniel@haxx.se> | 2021-04-26 11:11:59 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2021-04-26 14:27:45 +0200 |
commit | 9fc284427c96cc2e89c51f79080f16c44a10594d (patch) | |
tree | e178911c7506291bec646ec7d9d7ed84202adbe5 | |
parent | f154ae9de36eb11480e56ae793105a10aefeb37e (diff) | |
download | curl-9fc284427c96cc2e89c51f79080f16c44a10594d.tar.gz |
wolfssl: handle SSL_write() returns 0 for error
Reported-by: Timo Lange
Closes #6967
-rw-r--r-- | lib/vtls/wolfssl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/vtls/wolfssl.c b/lib/vtls/wolfssl.c index a0afe7418..a16612015 100644 --- a/lib/vtls/wolfssl.c +++ b/lib/vtls/wolfssl.c @@ -786,7 +786,7 @@ static ssize_t wolfssl_send(struct Curl_easy *data, int memlen = (len > (size_t)INT_MAX) ? INT_MAX : (int)len; int rc = SSL_write(backend->handle, mem, memlen); - if(rc < 0) { + if(rc <= 0) { int err = SSL_get_error(backend->handle, rc); switch(err) { |