Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ec903d2

Browse files
committed
Improve comment.
Based on the old comment, it took me a while to figure out what the problem was. The importnat detail is that SSL_read() can return WANT_READ even though some raw data was received from the socket.
1 parent 73cfa37 commit ec903d2

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/interfaces/libpq/fe-misc.c

+4-3
Original file line numberDiff line numberDiff line change
@@ -744,9 +744,10 @@ pqReadData(PGconn *conn)
744744
* the file selected for reading already.
745745
*
746746
* In SSL mode it's even worse: SSL_read() could say WANT_READ and then
747-
* data could arrive before we make the pqReadReady() test. So we must
748-
* play dumb and assume there is more data, relying on the SSL layer to
749-
* detect true EOF.
747+
* data could arrive before we make the pqReadReady() test, but the
748+
* second SSL_read() could still say WANT_READ because the data received
749+
* was not a complete SSL record. So we must play dumb and assume there
750+
* is more data, relying on the SSL layer to detect true EOF.
750751
*/
751752

752753
#ifdef USE_SSL

0 commit comments

Comments
 (0)