diff --git a/src/Mod/Sketcher/App/freegcs/GCS.cpp b/src/Mod/Sketcher/App/freegcs/GCS.cpp index a24aa0cca0..5f8ea18501 100644 --- a/src/Mod/Sketcher/App/freegcs/GCS.cpp +++ b/src/Mod/Sketcher/App/freegcs/GCS.cpp @@ -748,7 +748,9 @@ void System::initSolution() } VEC_I components(boost::num_vertices(g)); - int componentsSize = boost::connected_components(g, &components[0]); + int componentsSize = 0; + if (!components.empty()) + componentsSize = boost::connected_components(g, &components[0]); // identification of equality constraints and parameter reduction std::set reducedConstrs; // constraints that will be eliminated through reduction