diff options
author | Peter Geoghegan <pg@bowt.ie> | 2025-04-28 12:49:17 -0400 |
---|---|---|
committer | Peter Geoghegan <pg@bowt.ie> | 2025-04-28 12:49:17 -0400 |
commit | ce72e7e02e1c9075f8dd492f55281398d0721eb8 (patch) | |
tree | 5c19957c217eb49c91e3e1be354db0d7e4c68942 | |
parent | b75fedcab7916e1c955dbab565b7ad0cee6b37c6 (diff) | |
download | postgresql-ce72e7e02e1c9075f8dd492f55281398d0721eb8.tar.gz postgresql-ce72e7e02e1c9075f8dd492f55281398d0721eb8.zip |
Fix obsolete nbtree array advancement comment.
Checking if another primitive scan is required after all once the next
leaf page was moved from _bt_checkkeys to its _bt_readpage caller by
commit 9a2e2a28. Update a comment that incorrectly described the
recheck mechanism as something that takes place in _bt_checkkeys.
Also fix an older typo in related code comments.
-rw-r--r-- | src/backend/access/nbtree/nbtutils.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/access/nbtree/nbtutils.c b/src/backend/access/nbtree/nbtutils.c index c899168c995..11802a4c215 100644 --- a/src/backend/access/nbtree/nbtutils.c +++ b/src/backend/access/nbtree/nbtutils.c @@ -1110,7 +1110,7 @@ _bt_rewind_nonrequired_arrays(IndexScanDesc scan, ScanDirection dir) * * readpagetup callers must only call here when _bt_check_compare already set * continuescan=false. We help these callers deal with _bt_check_compare's - * inability to distinguishing between the < and > cases (it uses equality + * inability to distinguish between the < and > cases (it uses equality * operator scan keys, whereas we use 3-way ORDER procs). These callers pass * a _bt_check_compare-set sktrig value that indicates which scan key * triggered the call (!readpagetup callers just pass us sktrig=0 instead). @@ -1950,7 +1950,7 @@ _bt_advance_array_keys(IndexScanDesc scan, BTReadPageState *pstate, * keys for one or more truncated attribute values (scan keys required in * _either_ scan direction). * - * There is a chance that _bt_checkkeys (which checks so->scanBehind) will + * There is a chance that _bt_readpage (which checks so->scanBehind) will * find that even the sibling leaf page's finaltup is < the new array * keys. When that happens, our optimistic policy will have incurred a * single extra leaf page access that could have been avoided. |