]> granicus.if.org Git - postgresql/commit
Fix similar_escape() to convert parentheses to non-capturing style.
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 2 Jan 2010 20:59:16 +0000 (20:59 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 2 Jan 2010 20:59:16 +0000 (20:59 +0000)
commite15d53e7a419dcff49e108c78c8f70be6b18598b
tree5a9bd276cfdee5fe4ff14f7e9eddf6f51c5a36ba
parent2b59274c0925ca980748edf57723f3c3e026f619
Fix similar_escape() to convert parentheses to non-capturing style.
This is needed to avoid unwanted interference with SUBSTRING behavior,
as per bug #5257 from Roman Kononov.  Also, add some basic intelligence
about character classes (bracket expressions) since we now have several
behaviors that aren't appropriate inside a character class.

As with the previous patch in this area, I'm reluctant to back-patch
since it might affect applications that are relying on the prior
behavior.
src/backend/utils/adt/regexp.c