mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-02-17 19:30:00 +08:00
Fix incorrect cleanup of tsquery in ts_rewrite(). Per bug #4933 by
Aaron Marcuse-Kubitza <aaronmk@blackducksoftware.com>
This commit is contained in:
parent
4b284aff65
commit
a142498e76
@ -174,12 +174,12 @@ dropvoidsubtree(QTNode * root)
|
||||
|
||||
root->nchild = j;
|
||||
|
||||
if (root->valnode->val == (int4) '!' && root->nchild == 0)
|
||||
if (root->nchild == 0)
|
||||
{
|
||||
QTNFree(root);
|
||||
root = NULL;
|
||||
}
|
||||
else if (root->nchild == 1)
|
||||
else if (root->nchild == 1 && root->valnode->val != (int4) '!')
|
||||
{
|
||||
QTNode *nroot = root->child[0];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user