Created
November 12, 2012 21:06
-
-
Save anonymous/4061896 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/libwaitress/waitress.c b/src/libwaitress/waitress.c | |
index ce2a254..88c309e 100644 | |
--- a/src/libwaitress/waitress.c | |
+++ b/src/libwaitress/waitress.c | |
@@ -537,6 +537,10 @@ static WaitressReturn_t WaitressGnutlsRead (void *data, char *buf, | |
ssize_t ret = gnutls_record_recv (waith->request.tlsSession, buf, size); | |
if (ret < 0) { | |
+ if (ret == GNUTLS_E_PREMATURE_TERMINATION) { | |
+ *retSize = 0; | |
+ return waith->request.readWriteRet; | |
+ } | |
return WAITRESS_RET_TLS_READ_ERR; | |
} else { | |
*retSize = ret; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
what the hell do I do with this?