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

Commit0d906b2

Browse files
committed
Fix handling of partitioned index in RelationGetNumberOfBlocksInFork()
Since a partitioned index doesn't have storage, getting the number ofblocks from it will not give sensible results. Existing callersalready check that they don't call it that way, so there doesn'tappear to be a live problem. But for correctness, handleRELKIND_PARTITIONED_INDEX together with the other non-storagerelkinds.Reviewed-by: Michael Paquier <michael@paquier.xyz>Reviewed-by: Alvaro Herrera <alvherre@alvh.no-ip.org>Discussion:https://www.postgresql.org/message-id/1d3a5fbe-f48b-8bea-80da-9a5c4244aef9@enterprisedb.com
1 parent78ab944 commit0d906b2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎src/backend/storage/buffer/bufmgr.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2929,7 +2929,6 @@ RelationGetNumberOfBlocksInFork(Relation relation, ForkNumber forkNum)
29292929
{
29302930
caseRELKIND_SEQUENCE:
29312931
caseRELKIND_INDEX:
2932-
caseRELKIND_PARTITIONED_INDEX:
29332932
returnsmgrnblocks(RelationGetSmgr(relation),forkNum);
29342933

29352934
caseRELKIND_RELATION:
@@ -2951,6 +2950,7 @@ RelationGetNumberOfBlocksInFork(Relation relation, ForkNumber forkNum)
29512950
caseRELKIND_VIEW:
29522951
caseRELKIND_COMPOSITE_TYPE:
29532952
caseRELKIND_FOREIGN_TABLE:
2953+
caseRELKIND_PARTITIONED_INDEX:
29542954
caseRELKIND_PARTITIONED_TABLE:
29552955
default:
29562956
Assert(false);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp