aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeHashjoin.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2015-11-07 12:43:24 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2015-11-07 12:43:24 -0500
commit44fc25153681f0d3814275926f3c626a3f283cc2 (patch)
tree974d930476bacaec873c5e5c4c2875a35afa71ea /src/backend/executor/nodeHashjoin.c
parent695012a0d585844130bf3d82ad0b4ebe0b7bf581 (diff)
downloadpostgresql-44fc25153681f0d3814275926f3c626a3f283cc2.tar.gz
postgresql-44fc25153681f0d3814275926f3c626a3f283cc2.zip
Fix enforcement of restrictions inside regexp lookaround constraints.
Lookahead and lookbehind constraints aren't allowed to contain backrefs, and parentheses within them are always considered non-capturing. Or so says the manual. But the regexp parser forgot about these rules once inside a parenthesized subexpression, so that constructs like (\w)(?=(\1)) were accepted (but then not correctly executed --- a case like this acted like (\w)(?=\w), without any enforcement that the two \w's match the same text). And in (?=((foo))) the innermost parentheses would be counted as capturing parentheses, though no text would ever be captured for them. To fix, properly pass down the "type" argument to the recursive invocation of parse(). Back-patch to all supported branches; it was agreed that silent misexecution of such patterns is worse than throwing an error, even though new errors in minor releases are generally not desirable.
Diffstat (limited to 'src/backend/executor/nodeHashjoin.c')
0 files changed, 0 insertions, 0 deletions