mirror of
https://github.com/postgres/postgres.git
synced 2025-04-21 12:05:57 +03:00
Avoid uninitialized bits in the result of QTN2QT().
Found with additional valgrind testing. Noah Misch
This commit is contained in:
parent
59a4a571d3
commit
cc24fb418d
@ -336,7 +336,7 @@ QTN2QT(QTNode *in)
|
|||||||
cntsize(in, &sumlen, &nnode);
|
cntsize(in, &sumlen, &nnode);
|
||||||
len = COMPUTESIZE(nnode, sumlen);
|
len = COMPUTESIZE(nnode, sumlen);
|
||||||
|
|
||||||
out = (TSQuery) palloc(len);
|
out = (TSQuery) palloc0(len);
|
||||||
SET_VARSIZE(out, len);
|
SET_VARSIZE(out, len);
|
||||||
out->size = nnode;
|
out->size = nnode;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user