aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/gist/gist.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/gist/gist.c')
-rw-r--r--src/backend/access/gist/gist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/access/gist/gist.c b/src/backend/access/gist/gist.c
index efa5286c1f4..5003204df4a 100644
--- a/src/backend/access/gist/gist.c
+++ b/src/backend/access/gist/gist.c
@@ -1347,7 +1347,7 @@ text_range_out(TXTRANGE *r)
if (r == NULL)
return (NULL);
- result = (char *) palloc(16 + VARSIZE(TRLOWER(r)) + VARSIZE(TRUPPER(r))
+ result = (char *) palloc(NAMEDATALEN + VARSIZE(TRLOWER(r)) + VARSIZE(TRUPPER(r))
- 2 * VARHDRSZ);
lower = (char *) palloc(VARSIZE(TRLOWER(r)) + 1 - VARHDRSZ);