mirror of
https://github.com/postgres/postgres.git
synced 2025-07-02 09:02:37 +03:00
1. Pass GISTENTRYs to giststate->penaltyFn by pointers, not by vals.
2. Re-initialize keys in gistrescan (if gist used in inner scan).
This commit is contained in:
@ -987,7 +987,7 @@ gistchoose(Relation r, Page p, IndexTuple it, /* it has compressed entry */
|
||||
size = IndexTupleSize(datum) - sizeof(IndexTupleData);
|
||||
datum += sizeof(IndexTupleData);
|
||||
gistdentryinit(giststate,&entry,datum,r,p,i,size,FALSE);
|
||||
(giststate->penaltyFn)(entry, identry, &usize);
|
||||
(giststate->penaltyFn)(&entry, &identry, &usize);
|
||||
if (which_grow < 0 || usize < which_grow) {
|
||||
which = i;
|
||||
which_grow = usize;
|
||||
|
Reference in New Issue
Block a user