--- xchat-2.6.6/src/common/ssl.c.orig 2006-10-07 10:21:57.000000000 +0100
+++ xchat-2.6.6/src/common/ssl.c 2006-10-07 10:24:12.000000000 +0100
@@ -22,6 +22,7 @@
#include <time.h> /* asctime() */
#include <string.h> /* strncpy() */
#include "ssl.h" /* struct cert_info */
+#include "inet.h" /* would_block() */
#include "../../config.h" /* HAVE_SNPRINTF */
#ifndef HAVE_SNPRINTF
@@ -256,7 +257,8 @@ _SSL_recv (SSL * ssl, char *buf, int len
break;
case SSL_ERROR_SYSCALL:
/* ??? */
- perror ("SSL_read/read");
+ if (!would_block())
+ perror ("SSL_read/read");
break;
case SSL_ERROR_ZERO_RETURN:
/* fprintf(stdeerr, "SSL closed on read\n"); */