GNUTLS: rb_ssl_read_or_write(): Use macro to refer to session context

This commit is contained in:
Aaron Jones 2016-09-16 22:17:56 +00:00
parent 939d7ec7fe
commit d4e71871c0
No known key found for this signature in database
GPG key ID: EC6F86EE9CD840B5

View file

@ -303,12 +303,11 @@ static ssize_t
rb_ssl_read_or_write(const int r_or_w, rb_fde_t *const F, void *const rbuf, const void *const wbuf, const size_t count)
{
ssize_t ret;
gnutls_session_t *const ssl = F->ssl;
if(r_or_w == 0)
ret = gnutls_record_recv(*ssl, rbuf, count);
ret = gnutls_record_recv(SSL_P(F), rbuf, count);
else
ret = gnutls_record_send(*ssl, wbuf, count);
ret = gnutls_record_send(SSL_P(F), wbuf, count);
if(ret < 0)
{