mirror of
https://github.com/cesanta/mongoose.git
synced 2026-11-06 15:51:25 +00:00
fix no room
This commit is contained in:
1 parent
db658918c6
commit
416dc7beae
4 files changed
+16
-10
No files matched your search
+1
-1
@@ -201,7 +201,7 @@ size_t mg_tls_pending(struct mg_connection *c) {
|
||||
long mg_tls_recv(struct mg_connection *c, void *buf, size_t len) {
|
||||
struct mg_tls *tls = (struct mg_tls *) c->tls;
|
||||
long n = mbedtls_ssl_read(&tls->ssl, (unsigned char *) buf, len);
|
||||
if (!c->is_tls_hs && buf == NULL && n == 0) return 0; // TODO(): MIP
|
||||
if (!c->is_tls_hs && (buf == NULL || len == 0) && n == 0) return 0; // MIP
|
||||
if (n == MBEDTLS_ERR_SSL_WANT_READ || n == MBEDTLS_ERR_SSL_WANT_WRITE)
|
||||
return MG_IO_WAIT;
|
||||
#if defined(MBEDTLS_ERR_SSL_RECEIVED_NEW_SESSION_TICKET)
|
||||
|
||||
Reference in new issue
Block a user