Oct 2026

1 commit
Return INT_MAX or INT_MIN from strtoint() on overflow.
30 Oct 2026Tom LanemasterunreleasedREL_19_STABLE19rc2REL_18_STABLE18.7REL_17_STABLE17.12REL_16_STABLE16.16REL_15_STABLE15.20REL_14_STABLE14.25
LLM analysis, 100% suremodified before commitmoderate changesfrom patchset #11 of 1 reviewer saw the final version

The commit implements #1 in src/common/string.c but replaces its explicit upper/lower bound checks and early returns with the existing cast-and-compare test followed by sign-based clamping, and rewrites the function comment. Tom Lane explained that this avoids potential always-false comparison warnings on platforms with 32-bit long #9.

  • Tom Lanesaw the final versiontrailerTom supported preserving overflow direction #5, advocated backpatching #7, and as committer reviewed and revised the final implementation #9.

Credits across 1 commit

Author
Chao Li1
Reviewer
Tom Lane1
Committer
Tom Lane1