mirror of
https://github.com/postgres/postgres.git
synced 2026-01-26 09:41:40 +03:00
Tighten up assertion on a local variable
'lineindex' is 0-based, as mentioned in the comments. Backpatch to v18 where the assertion was added. Author: ChangAo Chen <cca5507@qq.com> Reviewed-by: Chao Li <li.evan.chao@gmail.com> Discussion: https://www.postgresql.org/message-id/tencent_A84F3C810365BB9BD08442955AE494141907@qq.com Backpatch-through: 18
This commit is contained in:
@@ -1077,7 +1077,7 @@ continue_page:
|
||||
ItemId lpp;
|
||||
OffsetNumber lineoff;
|
||||
|
||||
Assert(lineindex <= scan->rs_ntuples);
|
||||
Assert(lineindex < scan->rs_ntuples);
|
||||
lineoff = scan->rs_vistuples[lineindex];
|
||||
lpp = PageGetItemId(page, lineoff);
|
||||
Assert(ItemIdIsNormal(lpp));
|
||||
|
||||
Reference in New Issue
Block a user