search for: 3f7c744

Displaying 1 result from an estimated 1 matches for "3f7c744".

Did you mean: 371744
2019 Jun 06
1
[libnbd PATCH] tls: Check for pending bytes in gnutls buffers
...s_to_issue) SET_NEXT_STATE (%ISSUE_COMMAND.START); + else { + assert (h->sock); + if (h->sock->ops->pending && h->sock->ops->pending (h->sock)) + SET_NEXT_STATE (%REPLY.START); + } return 0; DEAD: diff --git a/lib/crypto.c b/lib/crypto.c index 3f7c744..e0f173f 100644 --- a/lib/crypto.c +++ b/lib/crypto.c @@ -181,6 +181,12 @@ tls_send (struct nbd_handle *h, return r; } +static bool +tls_pending (struct socket *sock) +{ + return gnutls_record_check_pending (sock->u.tls.session) > 0; +} + static int tls_get_fd (struct socket *sock) {...