File tree 1 file changed +3
-1
lines changed
src/backend/access/transam
1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -7679,6 +7679,7 @@ PreCheckPointGuts(int flags)
7679
7679
if (flags & CHECKPOINT_IS_SHUTDOWN )
7680
7680
{
7681
7681
CheckPointReplicationState (flags );
7682
+ CheckPointBuffers (flags );
7682
7683
/*
7683
7684
* pgstat_write_statsfile will be called later by before_shmem_exit() hook, but by then it's too late
7684
7685
* to write WAL records. In Neon, pgstat_write_statsfile() writes the pgstats file to the WAL, so we have
@@ -7708,7 +7709,8 @@ CheckPointGuts(XLogRecPtr checkPointRedo, int flags)
7708
7709
CheckPointSUBTRANS ();
7709
7710
CheckPointMultiXact ();
7710
7711
CheckPointPredicate ();
7711
- CheckPointBuffers (flags );
7712
+ if (!(flags & CHECKPOINT_IS_SHUTDOWN ))
7713
+ CheckPointBuffers (flags );
7712
7714
7713
7715
/* Perform all queued up fsyncs */
7714
7716
TRACE_POSTGRESQL_BUFFER_CHECKPOINT_SYNC_START ();
You can’t perform that action at this time.
0 commit comments