From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Use OpenSSL's SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER flag. |
Date: | 2011-07-24 19:18:48 |
Message-ID: | E1Ql4CO-0006aT-OZ@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Use OpenSSL's SSL_MODE_ACCEPT_MOVING_WRITE_BUFFER flag.
This disables an entirely unnecessary "sanity check" that causes failures
in nonblocking mode, because OpenSSL complains if we move or compact the
write buffer. The only actual requirement is that we not modify pending
data once we've attempted to send it, which we don't. Per testing and
research by Martin Pihlak, though this fix is a lot simpler than his patch.
I put the same change into the backend, although it's less clear whether
it's necessary there. We do use nonblock mode in some situations in
streaming replication, so seems best to keep the same behavior in the
backend as in libpq.
Back-patch to all supported releases.
Branch
------
REL9_1_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/f9c0547aa205148cc62b692a99fde8c3f62bd058
Modified Files
--------------
src/backend/libpq/be-secure.c | 6 ++++++
src/interfaces/libpq/fe-secure.c | 6 ++++++
2 files changed, 12 insertions(+), 0 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2011-07-24 20:29:54 | pgsql: Improve libpq's error reporting for SSL failures. |
Previous Message | Bruce Momjian | 2011-07-24 05:43:58 | pgsql: In pg_upgrade on Windows, check if the directory is writable by |