Skip to content

Commit

Permalink
Use BT_READ instead of BUFFER_LOCK_SHARE where the latter crept in.
Browse files Browse the repository at this point in the history
  • Loading branch information
kgrittn committed Mar 13, 2015
1 parent 17313e3 commit 76118b5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/backend/access/nbtree/nbtsearch.c
Expand Up @@ -1385,7 +1385,7 @@ _bt_steppage(IndexScanDesc scan, ScanDirection dir)

/* XXX: Can walking left be lighter on the locking and pins? */
if (BTScanPosIsPinned(so->currPos))
LockBuffer(so->currPos.buf, BUFFER_LOCK_SHARE);
LockBuffer(so->currPos.buf, BT_READ);
else
so->currPos.buf = _bt_getbuf(rel, so->currPos.currPage, BT_READ);

Expand Down

0 comments on commit 76118b5

Please sign in to comment.