diff --git a/indexer/cell_coverer.hpp b/indexer/cell_coverer.hpp index 8afc068e53..fd98a88b62 100644 --- a/indexer/cell_coverer.hpp +++ b/indexer/cell_coverer.hpp @@ -156,6 +156,9 @@ inline void CoverRect(CoordT minX, CoordT minY, if (maxX > BoundsT::maxX) maxX = BoundsT::maxX; if (maxY > BoundsT::maxY) maxY = BoundsT::maxY; + if (minX >= maxX || minY >= maxY) + return; + CellIdT commonCell = CellIdConverter::Cover2PointsWithCell(minX, minY, maxX, maxY);