Sketcher: BSpline: Fix crash when cancelled while only one point with autoconstraint.

This commit is contained in:
PaddleStroke
2024-06-26 10:15:32 +02:00
committed by Chris Hennes
parent 1eaf89b485
commit 6a309e889e

View File

@@ -528,9 +528,15 @@ private:
// We must see if we need to create a B-spline before cancelling everything
if (state() == SelectMode::SeekSecond) {
// create B-spline from existing poles/knots
setState(SelectMode::End);
finish();
if (geoIds.size() > 1) {
// create B-spline from existing poles/knots
setState(SelectMode::End);
finish();
}
else {
// We don't want to finish() as that'll create auto-constraints
handleContinuousMode();
}
}
else {
DrawSketchHandler::quit();