kore

Kore is a web application platform for writing scalable, concurrent web based processes in C or Python.
Commits | Files | Refs | README | LICENSE | git clone https://git.kore.io/kore.git

commit cb13190e0d4ab93845807483665b5865e733242d
parent 16166d37bd1e653c51b0c3af635900652dae4550
Author: Joris Vink <joris@coders.se>
Date:   Mon,  5 Dec 2016 14:24:22 +0100

Call ERR_clear_error() before SSL_read() and SSL_write() calls.

Diffstat:
src/net.c | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/net.c b/src/net.c @@ -281,6 +281,7 @@ net_write_ssl(struct connection *c, int len, int *written) { int r; + ERR_clear_error(); r = SSL_write(c->ssl, (c->snb->buf + c->snb->s_off), len); if (c->tls_reneg > 1) return (KORE_RESULT_ERROR); @@ -321,6 +322,7 @@ net_read_ssl(struct connection *c, int *bytes) { int r; + ERR_clear_error(); r = SSL_read(c->ssl, (c->rnb->buf + c->rnb->s_off), (c->rnb->b_len - c->rnb->s_off));