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

Commit44e44bd

Browse files
Correct _bt_delitems_vacuum() lock comments.
The expectation within _bt_delitems_vacuum() is that caller has asuper-exclusive/cleanup buffer lock (not just a pin and a write lock).
1 parent1fa846f commit44e44bd

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

‎src/backend/access/nbtree/nbtpage.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -967,8 +967,9 @@ _bt_page_recyclable(Page page)
967967
* non-leaf page has to be done as part of an atomic action that includes
968968
* deleting the page it points to.
969969
*
970-
* This routine assumes that the caller has pinned and locked the buffer.
971-
* Also, the given deletable array *must* be sorted in ascending order.
970+
* This routine assumes that the caller has a super-exclusive write lock on
971+
* the buffer. Also, the given deletable array *must* be sorted in ascending
972+
* order.
972973
*
973974
* We record VACUUMs and b-tree deletes differently in WAL. Deletes must
974975
* generate recovery conflicts by accessing the heap inline, whereas VACUUMs
@@ -1049,8 +1050,9 @@ _bt_delitems_vacuum(Relation rel, Buffer buf,
10491050
*
10501051
* As above, must only be used on leaf pages.
10511052
*
1052-
* This routine assumes that the caller has pinned and locked the buffer.
1053-
* Also, the given itemnos *must* appear in increasing order in the array.
1053+
* This routine assumes that the caller has pinned and write locked the
1054+
* buffer. Also, the given itemnos *must* appear in increasing order in the
1055+
* array.
10541056
*
10551057
* This is nearly the same as _bt_delitems_vacuum as far as what it does to
10561058
* the page, but it needs to generate its own recovery conflicts by accessing

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp