Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit2f0491d

Browse files
committed
Document and clean up gistsplit.c.
Improve comments, rename some variables and functions, slightly simplifya couple of APIs, in an attempt to make this code readable by people otherthan its original author.Even though this is essentially just cosmetic, back-patch to all activebranches, because otherwise it's going to make back-patching future fixesin this file very painful.
1 parent3ea1ab2 commit2f0491d

File tree

4 files changed

+319
-170
lines changed

4 files changed

+319
-170
lines changed

‎src/backend/access/gist/gist.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1238,18 +1238,12 @@ gistSplit(Relation r,
12381238
IndexTuple*lvectup,
12391239
*rvectup;
12401240
GistSplitVectorv;
1241-
GistEntryVector*entryvec;
12421241
inti;
12431242
SplitedPageLayout*res=NULL;
12441243

1245-
/* generate the item array */
1246-
entryvec=palloc(GEVHDRSZ+ (len+1)*sizeof(GISTENTRY));
1247-
entryvec->n=len+1;
1248-
12491244
memset(v.spl_lisnull, TRUE,sizeof(bool)*giststate->tupdesc->natts);
12501245
memset(v.spl_risnull, TRUE,sizeof(bool)*giststate->tupdesc->natts);
1251-
gistSplitByKey(r,page,itup,len,giststate,
1252-
&v,entryvec,0);
1246+
gistSplitByKey(r,page,itup,len,giststate,&v,0);
12531247

12541248
/* form left and right vector */
12551249
lvectup= (IndexTuple*)palloc(sizeof(IndexTuple)* (len+1));

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp