mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-16 18:12:10 +00:00
💥Fix Crash with painted Line in some corrupted models (#12806)
Safeguard EdgeGrid.hpp
This commit is contained in:
@@ -224,6 +224,8 @@ public:
|
||||
iy += 1;
|
||||
assert(iy <= iyb);
|
||||
}
|
||||
if (ix < 0 || iy < 0 || ix >= (int64_t)m_cols || iy >= (int64_t)m_rows)
|
||||
return;
|
||||
if (! visitor(iy, ix))
|
||||
return;
|
||||
} while (ix != ixb || iy != iyb);
|
||||
@@ -245,6 +247,8 @@ public:
|
||||
iy -= 1;
|
||||
assert(iy >= iyb);
|
||||
}
|
||||
if (ix < 0 || iy < 0 || ix >= (int64_t)m_cols || iy >= (int64_t)m_rows)
|
||||
return;
|
||||
if (! visitor(iy, ix))
|
||||
return;
|
||||
} while (ix != ixb || iy != iyb);
|
||||
@@ -270,6 +274,8 @@ public:
|
||||
iy += 1;
|
||||
assert(iy <= iyb);
|
||||
}
|
||||
if (ix < 0 || iy < 0 || ix >= (int64_t)m_cols || iy >= (int64_t)m_rows)
|
||||
return;
|
||||
if (! visitor(iy, ix))
|
||||
return;
|
||||
} while (ix != ixb || iy != iyb);
|
||||
@@ -307,6 +313,8 @@ public:
|
||||
iy -= 1;
|
||||
assert(iy >= iyb);
|
||||
}
|
||||
if (ix < 0 || iy < 0 || ix >= (int64_t)m_cols || iy >= (int64_t)m_rows)
|
||||
return;
|
||||
if (! visitor(iy, ix))
|
||||
return;
|
||||
} while (ix != ixb || iy != iyb);
|
||||
|
||||
Reference in New Issue
Block a user