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

Commit8bbbcb9

Browse files
committed
Fix bug in the new GIN incomplete-split code.
Inserting a downlink to an internal page clears the incomplete-split flagof the child's left sibling, so the left sibling's LSN also needs to beupdated and it needs to be marked dirty. The codepath for an insertion gotthis right, but the case where the internal node is split because ofinserting the new downlink missed that.
1 parent6eff0ac commit8bbbcb9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

‎src/backend/access/gin/ginbtree.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -543,6 +543,8 @@ ginPlaceToPage(GinBtree btree, GinBtreeStack *stack,
543543

544544
MarkBufferDirty(rbuffer);
545545
MarkBufferDirty(stack->buffer);
546+
if (BufferIsValid(childbuf))
547+
MarkBufferDirty(childbuf);
546548

547549
/*
548550
* Restore the temporary copies over the real buffers. But don't free
@@ -571,6 +573,8 @@ ginPlaceToPage(GinBtree btree, GinBtreeStack *stack,
571573
PageSetLSN(BufferGetPage(rbuffer),recptr);
572574
if (stack->parent==NULL)
573575
PageSetLSN(BufferGetPage(lbuffer),recptr);
576+
if (BufferIsValid(childbuf))
577+
PageSetLSN(childpage,recptr);
574578
}
575579
END_CRIT_SECTION();
576580

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp