Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7e4911b

Browse files
committed
Fix variable confusion in BufferSync().
As noted by Heikki Linnakangas, the previous coding confused the "flags"variable with the "mask" variable. The affect of this appears to be thatunlogged buffers would get written out at every checkpoint rather thanonly at shutdown time. Although that's arguably an acceptable failuremode, I'm back-patching this change, since it seems like a poor idea torely on this happening to work.
1 parentbd0e74a commit7e4911b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/backend/storage/buffer/bufmgr.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1191,7 +1191,7 @@ BufferSync(int flags)
11911191
* buffers. But at shutdown time, we write all dirty buffers.
11921192
*/
11931193
if (!(flags&CHECKPOINT_IS_SHUTDOWN))
1194-
flags |=BM_PERMANENT;
1194+
mask |=BM_PERMANENT;
11951195

11961196
/*
11971197
* Loop over all buffers, and mark the ones that need to be written with

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp