model-writtenrun 3900 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Wei Sun proposed setting lasterrno when dir_existsfile() fails to open a file, treating its omission as a possible gap in pg_basebackup error handling #1.
- Bruce Momjian questioned recording ENOENT because the function checks existence and returns a boolean, while suggesting that other open failures might warrant recording #2.
- Bruce Momjian then questioned how callers would know to inspect lasterrno when both existence and nonexistence are valid results #3.
- Bharath Rupireddy agreed that nonexistence is expected, observed that callers do not inspect errno, and suggested documenting why lasterrno is left unset #4.
- Bruce Momjian adopted the documentation approach in 3fdc1d2693 and posted the identical patch with confirmation that it had landed on master #5; the original behavioral change was left out.