1
0
mirror of https://github.com/lammertb/libhttp.git synced 2025-12-22 04:02:04 +03:00

Fix copy/paste error

This commit is contained in:
bel
2015-08-04 22:31:48 +02:00
parent 29e2d1a6e9
commit f08f7ec8bd

View File

@@ -3027,7 +3027,7 @@ static int push(struct mg_context *ctx,
n = SSL_write(ssl, buf, len); n = SSL_write(ssl, buf, len);
if (n <= 0) { if (n <= 0) {
err = SSL_get_error(ssl, n); err = SSL_get_error(ssl, n);
if ((err == 5 /* SSL_ERROR_SYSCALL */) && (nread==-1)) { if ((err == 5 /* SSL_ERROR_SYSCALL */) && (n == -1)) {
err = ERRNO; err = ERRNO;
} else { } else {
DEBUG_TRACE("SSL_write() failed, error %d", err); DEBUG_TRACE("SSL_write() failed, error %d", err);
@@ -3151,7 +3151,7 @@ pull(FILE *fp, struct mg_connection *conn, char *buf, int len, double timeout)
nread = SSL_read(conn->ssl, buf, len); nread = SSL_read(conn->ssl, buf, len);
if (nread <= 0) { if (nread <= 0) {
err = SSL_get_error(conn->ssl, nread); err = SSL_get_error(conn->ssl, nread);
if ((err == 5 /* SSL_ERROR_SYSCALL */) && (nread==-1)) { if ((err == 5 /* SSL_ERROR_SYSCALL */) && (nread == -1)) {
err = ERRNO; err = ERRNO;
} else { } else {
DEBUG_TRACE("SSL_read() failed, error %d", err); DEBUG_TRACE("SSL_read() failed, error %d", err);