From 3fea625e9ddfbf19eb4fc32c9704b6e4300fed6b Mon Sep 17 00:00:00 2001 From: "Vadim B. Mikheev" Date: Tue, 28 Sep 1999 11:41:09 +0000 Subject: Make tree compilable (+WAL). --- src/backend/access/transam/xlog.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/backend/access/transam/xlog.c') diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c index f1b80d40270..2a7d60d3aac 100644 --- a/src/backend/access/transam/xlog.c +++ b/src/backend/access/transam/xlog.c @@ -2,6 +2,7 @@ #include #include #include +#include #include "postgres.h" #include "access/xlog.h" @@ -1376,12 +1377,10 @@ CreateCheckPoint(bool shutdown) /* Get REDO record ptr */ while (!TAS(&(XLogCtl->insert_lck))) { - struct timeval delay; + struct timeval delay = {0, 5000}; if (shutdown) elog(STOP, "XLog insert lock is busy while data base is shutting down"); - delay.tv_sec = 0; - delay.tv_usec = 0; (void) select(0, NULL, NULL, NULL, &delay); } freespace = ((char*) Insert->currpage) + BLCKSZ - Insert->currpos; @@ -1408,7 +1407,7 @@ CreateCheckPoint(bool shutdown) checkPoint.nextOid = ShmemVariableCache->nextOid; SpinRelease(OidGenLockId); - FlushBufferPool(false); + FlushBufferPool(); /* Get UNDO record ptr */ -- cgit v1.2.3