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

Commitef777cb

Browse files
committed
Remove unused variable in statext_mcv_serialize()
The itemlen variable used to be referenced in multiple places, but sincereworking the serialization code it's used only in one assert. Fixed byremoving the variable and calling the macro from the assert directly.Backpatch to 12, where this code was introduced.Reported-by: Jeff JanesDiscussion:https://postgr.es/m/CAMkU=1zc_ovH9NZd_9ovuiEWkF9yX06URUDdXCmgDydf-bqB5A@mail.gmail.com
1 parent02e95a5 commitef777cb

File tree

1 file changed

+1
-2
lines changed
  • src/backend/statistics

1 file changed

+1
-2
lines changed

‎src/backend/statistics/mcv.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -911,10 +911,9 @@ statext_mcv_serialize(MCVList *mcvlist, VacAttrStats **stats)
911911
for (i=0;i<mcvlist->nitems;i++)
912912
{
913913
MCVItem*mcvitem=&mcvlist->items[i];
914-
intitemlen=ITEM_SIZE(dim);
915914

916915
/* don't write beyond the allocated space */
917-
Assert(ptr <= (endptr-itemlen));
916+
Assert(ptr <= (endptr-ITEM_SIZE(dim)));
918917

919918
/* copy NULL and frequency flags into the serialized MCV */
920919
memcpy(ptr,mcvitem->isnull,sizeof(bool)*ndims);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp