diff --git a/src/libslic3r/MeshBoolean.cpp b/src/libslic3r/MeshBoolean.cpp index f58ae0bfe..599ac4784 100644 --- a/src/libslic3r/MeshBoolean.cpp +++ b/src/libslic3r/MeshBoolean.cpp @@ -208,16 +208,20 @@ static bool _cgal_intersection(CGALMesh &A, CGALMesh &B, CGALMesh &R) template void _cgal_do(Op &&op, CGALMesh &A, CGALMesh &B) { bool success = false; + bool hw_fail = false; try { CGALMesh result; try_catch_signal({SIGSEGV, SIGFPE}, [&success, &A, &B, &result, &op] { success = op(A, B, result); - }, [&] { success = false; }); + }, [&] { hw_fail = true; }); A = std::move(result); // In-place operation does not work } catch (...) { success = false; } + if (hw_fail) + throw Slic3r::HardCrash("CGAL mesh boolean operation crashed."); + if (! success) throw Slic3r::RuntimeError("CGAL mesh boolean operation failed."); } diff --git a/src/libslic3r/SLAPrintSteps.cpp b/src/libslic3r/SLAPrintSteps.cpp index b267116e9..4a8d0d4be 100644 --- a/src/libslic3r/SLAPrintSteps.cpp +++ b/src/libslic3r/SLAPrintSteps.cpp @@ -453,8 +453,7 @@ void SLAPrint::Steps::drill_holes(SLAPrintObject &po) sla::remove_inside_triangles(mesh_view, interior, exclude_mask); } - - } catch (const std::runtime_error &) { + } catch (const Slic3r::RuntimeError &) { throw Slic3r::SlicingError(L( "Drilling holes into the mesh failed. " "This is usually caused by broken model. Try to fix it first."));