model-writtenrun 112 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Gowtham Reddy reported that trailing-decimal to_char() formats emitted embedded NUL bytes after the StringInfo conversion, exposing an older bug that truncated signs and literal suffixes, and supplied reproductions and successful test results in #1.
- Gowtham attached a patch that prevents NUM_numpart_to_char() from copying the number string’s terminator and adds regression checks for output length and preserved suffixes in #2.
- Tom Lane reproduced the older truncation behavior as far back as PostgreSQL 9.2 and proposed limiting the fix to master and version 19 because applications might depend on the longstanding behavior in older stable branches in #3.
- Tom committed the guard from #2 with an equivalent expression for the older buffer implementation, a comment correction, and a simplified regression test as 61bb221489, then announced that it had landed in master and version 19 in #4.
- Tom deferred changing whether the trailing decimal point itself is printed because that would be a larger behavioral change in #4, and Gowtham accepted that scope and thanked him in #5, closing the thread with the fix landed.