model-writtenrun 4636 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Nikolay Shaplov reported a fuzzing-discovered jsonb input crash in PostgreSQL 14 and 15, with a reduced reproducer involving a newline and a Unicode zero escape that also failed under UTF-8 #1.
- Tom Lane identified error exits in json_lex_string() that failed to advance token_terminator and supplied a fix using error-exit macros, clearer documentation, an assertion, and corrected regression expectations #2.
- Tom Lane committed #2 as 25a7812cd0 with only a comment clarification, fixing both crashes and misleading error contexts and backpatching the change to supported branches.
- After the fix landed, Yura Sokolov forwarded Nikita Glukhov's follow-up patch replacing macros with inline helpers, making lexer success and error handling more uniform, simplifying number lexing, and adding tests for the original bug and multibyte characters after surrogates #3.
- At the thread's end, the original fix had landed as 25a7812cd0, while the additional refactoring and tests in #3 remained proposed without a recorded review or landing.