From: Tom Lane Date: Fri, 22 Aug 2003 21:57:44 +0000 (+0000) Subject: Sigh, I'm an idiot ... SSL_ERROR_WANT_READ isn't an error condition X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=eca0f6d7757325e0f31a6ea4eb095eb75e02e915;p=users%2Fbernd%2Fpostgres.git Sigh, I'm an idiot ... SSL_ERROR_WANT_READ isn't an error condition at all, it just means 'no data available yet'. --- diff --git a/src/interfaces/libpq/fe-secure.c b/src/interfaces/libpq/fe-secure.c index 573c86c7c6..5e017e3422 100644 --- a/src/interfaces/libpq/fe-secure.c +++ b/src/interfaces/libpq/fe-secure.c @@ -269,6 +269,9 @@ pqsecure_read(PGconn *conn, void *ptr, size_t len) case SSL_ERROR_NONE: break; case SSL_ERROR_WANT_READ: + /* WANT_READ simply means no data available */ + n = 0; + break; case SSL_ERROR_WANT_WRITE: /* XXX to support nonblock I/O, we should return 0 here */ goto rloop;