From 3308467905aa157139d24375850cfe49ee90a0cf Mon Sep 17 00:00:00 2001 From: Teodor Sigaev Date: Thu, 7 Apr 2016 20:45:24 +0300 Subject: [PATCH] Zeroing unused parts ducring tsquery construction. Per investigation failure skink buildfarm member and RANDOMIZE_ALLOCATED_MEMORY help --- src/backend/utils/adt/tsquery_cleanup.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/backend/utils/adt/tsquery_cleanup.c b/src/backend/utils/adt/tsquery_cleanup.c index 126795504a..0f6ef6f541 100644 --- a/src/backend/utils/adt/tsquery_cleanup.c +++ b/src/backend/utils/adt/tsquery_cleanup.c @@ -347,7 +347,8 @@ makeNODE(int8 op, NODE *left, NODE *right) { NODE *node = palloc(sizeof(NODE)); - node->valnode = palloc(sizeof(QueryItem)); + /* zeroing allocation to prevent difference in unused bytes */ + node->valnode = palloc0(sizeof(QueryItem)); node->valnode->qoperator.type = QI_OPR; node->valnode->qoperator.oper = op; -- 2.40.0