The following bug has been logged on the website:
Bug reference: 18708
Logged by: Nikolay Shaplov (PostgresPro)
Email address: dhyan@nataraj.su
PostgreSQL version: 16.4
Operating system: Debian 12
Description:
Hi!
We've found a bug:
If you run
SELECT '' ~ '(?:[^\d\D]){0}';
it will assert with "lp->nouts == 0 && rp->nins == 0"
This behavior have been introduced in 2a0af7fe460 commit.
This bug have been found while fuzzing jsonpath_in function, and then
narrowed down to regex problem. Thanks to Andrey Bille for help with
narrowing sample down and finding commit that caused the problem.