From: Heikki Linnakangas Date: Tue, 8 Jul 2008 15:12:04 +0000 (+0000) Subject: Fix WAL file cutoff point calculation in pg_standby. X-Git-Url: http://waps.l3s.uni-hannover.de/gitweb/?a=commitdiff_plain;h=b05c44cb255e99b9ba9b58396a0298a6d2156eae;p=users%2Fbernd%2Fpostgres.git Fix WAL file cutoff point calculation in pg_standby. Patch by Simon Riggs, per bug report from Ferenc Felhoffer --- diff --git a/contrib/pg_standby/pg_standby.c b/contrib/pg_standby/pg_standby.c index 9879348cc1..5433985d26 100644 --- a/contrib/pg_standby/pg_standby.c +++ b/contrib/pg_standby/pg_standby.c @@ -320,7 +320,7 @@ SetWALFileNameForCleanup(void) if (seg_diff > seg) { log_diff++; - seg = MaxSegmentsPerLogFile - seg_diff; + seg = MaxSegmentsPerLogFile - (seg_diff - seg); } else seg -= seg_diff;