btree_gist: Fix memory allocation formula

This change has been suggested by the two authors listed in this commit,
both of them providing an incomplete solution (David's formula relied on
a "bytea *", while Bertrand's did not use palloc_array()).  The solution
provided in this commit uses GBT_VARKEY instead of the inconsistent
bytea for the allocation size, with a palloc_array().

The change related to Vsrt is one I am flipping to a more consistent
style, in passing.

Author: David Geier <[email protected]>
Author: Bertrand Drouvot <[email protected]>
Discussion: https://postgr.es/m/[email protected]
Discussion: 
https://postgr.es/m/[email protected]

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/5cf03552fbb43b2d2d11369d779f9b168ea9b87a

Modified Files
--------------
contrib/btree_gist/btree_utils_var.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Reply via email to