]> granicus.if.org Git - postgresql/commit
Fix memory leak during regular expression execution.
authorTom Lane <tgl@sss.pgh.pa.us>
Wed, 19 Mar 2014 15:09:24 +0000 (11:09 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Wed, 19 Mar 2014 15:09:37 +0000 (11:09 -0400)
commit7f857a511f84410631dea6590d4036c43170afc8
tree0e39bebc027a5a0f211a4a9af0a88b7ef8007b68
parent63817f86b57fc3d29b57787bca9d786218b7ee25
Fix memory leak during regular expression execution.

For a regex containing backrefs, pg_regexec() might fail to free all the
sub-DFAs that were created during execution, resulting in a permanent
(session lifespan) memory leak.  Problem was introduced by me in commit
587359479acbbdc95c8e37da40707e37097423f5.  Per report from Sandro Santilli;
diagnosis by Greg Stark.
src/backend/regex/regexec.c