model-writtenrun 3089 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Peter Eisentraut proposed opening libpq's password file before checking its permissions with fstat(), addressing a static-analyzer TOCTOU warning whose practical exploitability he considered unlikely #1.
- Aleksander Alekseev supported the simple fix to silence the analyzer while expressing uncertainty that the existing behavior posed a serious security issue #2.
- Andreas Karlsson endorsed the approach as more correct, observed that the old stat() call on Windows made little sense, and recommended committing #3.
- Peter committed the patch from #1 as e882bcae03, adding only a conditional-compilation guard around the stat_buf declaration and crediting both reviewers.
- Peter confirmed the commit in #4, closing the thread with the proposed change landed and no outstanding requests.