未验证 提交 073be714 编写于 作者: F Fang Zheng 提交者: GitHub

Use palloc() instead of palloc0() in buildGpQueryString() (#10875)

The buildGpQueryString() function should use palloc() instead of palloc0()
to allocate the buffer for holding the serialized query string, thus
avoiding the unnecessary cost of setting all bytes in buffer to zero.
Reviewed-by: NHeikki Linnakangas <hlinnaka@iki.fi>
Reviewed-by: NAshwin Agrawal <aashwin@vmware.com>
上级 624f460c
......@@ -910,7 +910,7 @@ buildGpQueryString(DispatchCommandQueryParms *pQueryParms,
sizeof(resgroupInfo.len) +
resgroupInfo.len;
shared_query = palloc0(total_query_len);
shared_query = palloc(total_query_len);
pos = shared_query;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册