Don't segfault on empty Nef_nary_x

This commit is contained in:
Thomas Krijnen 2020-06-07 15:25:18 +02:00
parent 6b679968c6
commit a86712d1aa
2 changed files with 4 additions and 2 deletions

View File

@ -52,7 +52,8 @@ class Nef_nary_intersection_3 {
}
Polyhedron get_intersection() {
if (queue.empty())
return empty;
while(queue.size() > 1)
intersect();
inserted = 0;

View File

@ -52,7 +52,8 @@ class Nef_nary_union_3 {
}
Polyhedron get_union() {
if (queue.empty())
return empty;
while(queue.size() > 1)
unite();
inserted = 0;