aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/xlog.c
diff options
context:
space:
mode:
authorNoah Misch <noah@leadboat.com>2013-06-12 19:50:14 -0400
committerNoah Misch <noah@leadboat.com>2013-06-12 19:50:14 -0400
commitfb435f40d5e34f85076a0af56b2f3bf7b86122b8 (patch)
tree314675c91827fe812600690f71ce46d653f1736f /src/backend/access/transam/xlog.c
parentff53890f687c7f6b2a10db6661e9c32faf832636 (diff)
downloadpostgresql-fb435f40d5e34f85076a0af56b2f3bf7b86122b8.tar.gz
postgresql-fb435f40d5e34f85076a0af56b2f3bf7b86122b8.zip
Observe array length in HaveVirtualXIDsDelayingChkpt().
Since commit f21bb9cfb5646e1793dcc9c0ea697bab99afa523, this function ignores the caller-provided length and loops until it finds a terminator, which GetVirtualXIDsDelayingChkpt() never adds. Restore the previous loop control logic. In passing, revert the addition of an unused variable by the same commit, presumably a debugging relic.
Diffstat (limited to 'src/backend/access/transam/xlog.c')
-rw-r--r--src/backend/access/transam/xlog.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c
index 0a573f7f65c..7210ca5fddb 100644
--- a/src/backend/access/transam/xlog.c
+++ b/src/backend/access/transam/xlog.c
@@ -6984,12 +6984,9 @@ CreateCheckPoint(int flags)
vxids = GetVirtualXIDsDelayingChkpt(&nvxids);
if (nvxids > 0)
{
- uint32 nwaits = 0;
-
do
{
pg_usleep(10000L); /* wait for 10 msec */
- nwaits++;
} while (HaveVirtualXIDsDelayingChkpt(vxids, nvxids));
}
pfree(vxids);