Add TLS_WANT to tls_read too. - geomyidae - a small C-based gopherd (mirror)
(HTM) git clone git://git.codemadness.org/geomyidae
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
(DIR) commit f827151059463740fbdd59834ce0620b81d80d61
(DIR) parent c70b510eb6ff2a91583e8dcd819af3fb7667bfa7
(HTM) Author: Christoph Lohmann <20h@r-36.net>
Date: Sat, 12 Aug 2023 19:19:26 +0200
Add TLS_WANT to tls_read too.
Diffstat:
M main.c | 4 ++++
1 file changed, 4 insertions(+), 0 deletions(-)
---
(DIR) diff --git a/main.c b/main.c
@@ -1126,6 +1126,10 @@ read_selector_again:
shufbuf,
sizeof(shufbuf)-1);
}
+ if (shuflen == TLS_WANT_POLLIN \
+ || shuflen == TLS_WANT_POLLOUT) {
+ continue;
+ }
if (shuflen == -1 && errno == EINTR)
continue;
for (shufpos = 0; shufpos < shuflen;