model-writtenrun 5974 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Alexander Kozhemyakin reported that selecting from pg_stat_slru triggered an AddressSanitizer global-buffer-overflow in pg_stat_get_slru() #1.
- Kyotaro Horiguchi identified an array access before the loop's termination check and considered delaying the assignment, using an explicit array bound, or checking pgstat_slru_name() in the loop condition; his first patch chose the last option to preserve independence from the array-size constant #2.
- Michael Paquier preferred delaying the assignment until after the existing termination check and noted that the array-size constant was private to pgstat.c #3, so Kyotaro supplied that smaller fix #4.
- Michael approved the revised fix and requested a sysviews regression query #5; Kyotaro added it while reporting that Valgrind had not detected the original overrun in his test, although exercising the view could help memory checkers #6.
- Michael committed the final patch with lightly revised test comments and a rewritten commit message as a45ed975c5, including backports through PostgreSQL 13, and announced completion #7.
- The thread ended with Kyotaro thanking Michael for committing, with no outstanding work identified #8.