From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Andres Freund <andres(at)anarazel(dot)de> |
Cc: | Shay Rojansky <roji(at)roji(dot)org>, hlinnaka(at)iki(dot)fi, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Some 9.5beta2 backend processes not terminating properly? |
Date: | 2015-12-30 18:26:34 |
Message-ID: | 20249.1451499994@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Andres Freund <andres(at)anarazel(dot)de> writes:
> There goes that theory. Amongst others. The aforementioned problem with
> waitfor doesn't seem to be actually armed because waitfor is only used
> if errno == EWOULDBLOCK || errno == EAGAIN.
Mumble. It is clearly possible that we'd reach the Assert failure if
SSL_read were to return -1 and set errno to EWOULDBLOCK or EAGAIN.
I doubt that is what is happening here, because those errnos don't
seem sensible for an EOF condition, but I'd still feel more comfortable
if be_tls_read/be_tls_write handled SSL_ERROR_SYSCALL like this:
if (n != -1)
{
errno = ECONNRESET;
n = -1;
}
+ else
+ {
+ /* just in case errno is EWOULDBLOCK/EAGAIN */
+ *waitfor = WL_SOCKET_READABLE | WL_SOCKET_WRITEABLE;
+ }
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Joe Conway | 2015-12-30 18:36:02 | custom parameters cannot be removed once set |
Previous Message | Andres Freund | 2015-12-30 18:25:13 | Re: Some 9.5beta2 backend processes not terminating properly? |