Skip to content

Commit 78493b7

Browse files
committed
Fix bug where pg_receivexlog goes into busy loop if -s option is set to 0.
The problem is that pg_receivexlog calls select(2) with timeout=0 and goes into busy loop when --status-interval option is set to 0. This bug was introduced by the commit, 74cbe96. Per report from Sawada Masahiko
1 parent 455044d commit 78493b7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/bin/pg_basebackup/receivelog.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1094,7 +1094,7 @@ CopyStreamReceive(PGconn *conn, long timeout, char **buffer)
10941094
* No data available. Wait for some to appear, but not longer than
10951095
* the specified timeout, so that we can ping the server.
10961096
*/
1097-
if (timeout > 0)
1097+
if (timeout != 0)
10981098
{
10991099
int ret;
11001100

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy