aboutsummaryrefslogtreecommitdiff
path: root/src/IO/tls.c
diff options
context:
space:
mode:
authorcorvid <devnull@localhost>2015-05-30 00:07:13 +0000
committercorvid <devnull@localhost>2015-05-30 00:07:13 +0000
commitd11a250d5739d106215d66700af3fc530566b604 (patch)
treef475503078fb296f9f9c4bb4a1ec5b7a32e235c8 /src/IO/tls.c
parent3d8b68e1bfde841e6d994d830dbc922256a6b7cf (diff)
let's not print tls alerts for 'close notify'
Diffstat (limited to 'src/IO/tls.c')
-rw-r--r--src/IO/tls.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/IO/tls.c b/src/IO/tls.c
index bab36644..2be2ebc0 100644
--- a/src/IO/tls.c
+++ b/src/IO/tls.c
@@ -185,8 +185,11 @@ static int Tls_conn_new(int fd, const DilloUrl *url, SSL *ssl)
static void Tls_info_cb(const SSL *ssl, int where, int ret)
{
if (where & SSL_CB_ALERT) {
- MSG("TLS ALERT on %s: %s\n", (where & SSL_CB_READ) ? "read" : "write",
- SSL_alert_desc_string_long(ret));
+ const char *str = SSL_alert_desc_string_long(ret);
+
+ if (strcmp(str, "close notify"))
+ MSG("TLS ALERT on %s: %s\n", (where & SSL_CB_READ) ? "read" : "write",
+ str);
}
}