model-writtenrun 5656 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Daria Lepikhova opened the thread with crashes caused by all-zero pages, crediting Anastasia Lubennikova with the initial discovery, and proposed rejecting those pages with errors in #1.
- Julien Rouhaud identified hardcoded test block sizes and proposed NULL results in #3; Michael Paquier supported NULL or empty results for scans and requested caller-specific handling instead of rejection in the shared helper in #5.
- Justin Pryzby supplied an inline fix for brin_page_items() accepting a non-BRIN index in #4, while Alexander Lakhin raised a separate unresolved invalid-page bug in #7.
- Daria revised selected functions to return NULL, made test page sizes configurable and added GiST coverage in #9, but reported that removing the remaining errors exposed Alexander's case again.
- Michael separated page-size, alignment and access-method validation into #11, generalizing get_page_from_raw() and incorporating Justin's BRIN check before tackling all-zero pages.
- After Justin corrected test-comment wording in #12, Michael committed that patch with only comment edits as 076f4d9539 and announced the backpatch in #13.
- Michael returned to all-zero pages in #15, replacing blanket rejection with explicit checks in individual functions while preserving hash's existing treatment of unused pages.
- Alexander reported that the earlier invalid-page failure persisted both on master and with the pending all-zero patch in #16, then supplied his Valgrind reproduction environment in #18.
- Michael traced that failure to reading beyond a heap page's nonexistent special area in #19, and Julien supplied a separate patch adding special-area sizes, GiST identifiers and btree leaf-level checks in #20.
- Michael revised Julien's patch for 32-bit alignment, portable tests and consistent diagnostics in #21; Julien accepted the revision and requested a clearer btree diagnostic in #22.
- Peter Geoghegan suggested amcheck-style validation in #24, but Michael argued in #25 that excessive validation could prevent inspecting useful contents of corrupted pages.
- Michael committed the revised sanity checks as 291e517a4d, adding the requested diagnostic wording and correcting GIN tests that otherwise accessed a dropped table, then announced application and backpatching in #26.
- The broader safety discussion continued: Robert Haas advocated more crash prevention in #27, Matthias van de Meent pointed to related core special-area work in #28, and Peter proposed additional bounded checks in #29 while explaining the difficulty of guaranteeing arbitrary page images safe in #31.
- Michael favored retaining raw-page inspection for realistic corruption investigations in #32; Maxim Orlov questioned assumptions about heap special-area sizes in #33, and Julien clarified that size checks reject incompatible pages without proving validity in #34.
- Michael finally committed the all-zero-page patch from #15 with light comment and rebase adjustments as cd4868a570, announcing backpatches through PostgreSQL 10 and completion of the thread's fixes in #35; broader hardening ideas remained outside these changes.