Browse Source

get usefull error-msg on SSL_read + SSL_ERROR_SYSCALL

git-svn-id: svn+ssh://svn.lighttpd.net/lighttpd/trunk@95 152afb58-edef-0310-8abb-c4023f1b3aa9
Jan Kneschke 17 years ago
parent
commit
f548172dac
  1. 18
      src/connections.c

18
src/connections.c

@ -216,6 +216,24 @@ static int connection_handle_read(server *srv, connection *con) {
switch ((r = SSL_get_error(con->ssl, len))) {
case SSL_ERROR_WANT_READ:
return 0;
case SSL_ERROR_SYSCALL:
switch(errno) {
default:
log_error_write(srv, __FILE__, __LINE__, "sddds", "SSL:",
len, r, errno,
strerror(errno));
break;
}
break;
case SSL_ERROR_ZERO_RETURN:
/* clean shutdown on the remote side */
if (r == 0) {
/* FIXME: later */
}
/* fall thourgh */
default:
log_error_write(srv, __FILE__, __LINE__, "sds", "SSL:",
r, ERR_error_string(ERR_get_error(), NULL));

Loading…
Cancel
Save