mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-01 16:58:30 +00:00
[tls socket] rm non-blocking i/o code
This commit is contained in:
parent
168a093508
commit
222cb6ba73
1 changed files with 2 additions and 5 deletions
|
@ -212,12 +212,9 @@ static int tls_read(lua_State *L) {
|
|||
lua_pushnil(L);
|
||||
return 1;
|
||||
} else {
|
||||
// All negative values are treated as errors
|
||||
lua_pushnil(L);
|
||||
if (ret == MBEDTLS_ERR_SSL_WANT_READ || ret == MBEDTLS_ERR_SSL_WANT_WRITE) {
|
||||
lua_pushstring(L, "EAGAIN");
|
||||
} else {
|
||||
lua_pushfstring(L, "Read error: %d", ret);
|
||||
}
|
||||
return 2;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue