Check if item pointer is valid [skip ci]

This commit is contained in:
Andrew Kane
2023-08-16 17:29:59 -07:00
parent b72a22b3c0
commit ed20d98777

View File

@@ -293,6 +293,9 @@ ConnectionExists(HnswElement e, HnswNeighborTuple ntup, int startIdx, int lm)
{
ItemPointer indextid = &ntup->indextids[startIdx + i];
if (!ItemPointerIsValid(indextid))
break;
if (ItemPointerGetBlockNumber(indextid) == e->blkno && ItemPointerGetOffsetNumber(indextid) == e->offno)
return true;
}