diff options
author | Felix Fietkau <nbd@openwrt.org> | 2016-01-23 19:37:57 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2016-01-23 19:37:57 +0100 |
commit | b1dede0e595410e1aa1380a33ca75b7ff684a077 (patch) | |
tree | 5eb59a55da23037dccaae695f1fe61c2c0478a38 | |
parent | 4fcd0174bab4f4237568e05fc6d552486e81ffa2 (diff) | |
download | ustream-ssl-b1dede0e595410e1aa1380a33ca75b7ff684a077.tar.gz |
polarssl: fix handling SSL close notification
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
-rw-r--r-- | ustream-polarssl.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ustream-polarssl.c b/ustream-polarssl.c index 57b3714..39bde21 100644 --- a/ustream-polarssl.c +++ b/ustream-polarssl.c @@ -242,6 +242,9 @@ __hidden int __ustream_ssl_read(struct ustream_ssl *us, char *buf, int len) if (ssl_do_wait(ret)) return U_SSL_PENDING; + if (ret == POLARSSL_ERR_SSL_PEER_CLOSE_NOTIFY) + return 0; + ustream_ssl_error(us, ret); return U_SSL_ERROR; } |