- Notifications
You must be signed in to change notification settings - Fork28
Commitfa7ff64
committed
Fix minor nbtree page deletion buffer lock issue.
Avoid accessing the deletion target page's special area during nbtreepage deletion at a point where there is no buffer lock held. This issuewas detected by a patch that extends Valgrind's memcheck tool to marknbtree pages that are unsafe to access (due to not having a buffer lockor buffer pin) as NOACCESS.We do hold a buffer pin at this point, and only access the special area,so the old approach was safe. Even still, it seems like a good idea totighten up the rules in this area. There is no reason to not simplyinsist on always holding a buffer lock (not just a pin) when accessingnbtree pages.Update some related comments in passing.Discussion:https://postgr.es/m/CAH2-WzkLgyN3zBvRZ1pkNJThC=xi_0gpWRUb_45eexLH1+k2_Q@mail.gmail.com1 parentf246ea3 commitfa7ff64
1 file changed
+9
-3
lines changedLines changed: 9 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1611 | 1611 |
| |
1612 | 1612 |
| |
1613 | 1613 |
| |
1614 |
| - | |
| 1614 | + | |
1615 | 1615 |
| |
1616 | 1616 |
| |
1617 | 1617 |
| |
| |||
1695 | 1695 |
| |
1696 | 1696 |
| |
1697 | 1697 |
| |
| 1698 | + | |
| 1699 | + | |
| 1700 | + | |
| 1701 | + | |
| 1702 | + | |
| 1703 | + | |
1698 | 1704 |
| |
1699 | 1705 |
| |
1700 | 1706 |
| |
| |||
1904 | 1910 |
| |
1905 | 1911 |
| |
1906 | 1912 |
| |
1907 |
| - | |
1908 |
| - | |
| 1913 | + | |
| 1914 | + | |
1909 | 1915 |
| |
1910 | 1916 |
| |
1911 | 1917 |
| |
|
0 commit comments
Comments
(0)