]> granicus.if.org Git - postgresql/commit
Fix bug in the test of file descriptor of current WAL file in pg_receivexlog.
authorFujii Masao <fujii@postgresql.org>
Wed, 19 Nov 2014 10:11:03 +0000 (19:11 +0900)
committerFujii Masao <fujii@postgresql.org>
Wed, 19 Nov 2014 10:11:03 +0000 (19:11 +0900)
commit78f91f1a888008f329b1a6db673713d25bbd819b
tree9101d4510e673cacbf056967a48dfe4aace0e02d
parent7900e94fbb2d36fe798f2deda56d71071957c0e0
Fix bug in the test of file descriptor of current WAL file in pg_receivexlog.

In pg_receivexlog, in order to check whether the current WAL file is
being opened or not, its file descriptor has to be checked against -1
as an invalid value. But, oops, 7900e94 added the incorrect test
checking the descriptor against 1. This commit fixes that bug.

Back-patch to 9.4 where the bug was added.

Spotted by Magnus Hagander
src/bin/pg_basebackup/receivelog.c