forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit3e383f9
committed
Avoid trying to write an empty WAL record in log_newpage_range().
If the last few pages in the specified range are empty (all zero),then log_newpage_range() could try to emit an empty WAL recordcontaining no FPIs. This at least upsets an Assert inReserveXLogInsertLocation, and might perhaps have bad real-worldconsequences in non-assert builds.This has been broken since log_newpage_range() was introduced,but the case was hard if not impossible to hit before commit3d6a984decided it was okay to leave VM and FSM pages intentionally zero.Nonetheless, it seems prudent to back-patch. log_newpage_range()was added in v12 but later back-patched, so this affects allsupported branches.Matthias van de Meent, per report from Justin PryzbyDiscussion:https://postgr.es/m/ZD1daibg4RF50IOj@telsasoft.com1 parentcd7cdc5 commit3e383f9
1 file changed
+4
-0
lines changedLines changed: 4 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1304 | 1304 |
| |
1305 | 1305 |
| |
1306 | 1306 |
| |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
1307 | 1311 |
| |
1308 | 1312 |
| |
1309 | 1313 |
| |
|
0 commit comments
Comments
(0)