Skip to content

Commit

Permalink
Sketcher: fix crash in function 'Convert to B-Spline'
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Feb 24, 2022
1 parent 8dd1140 commit 86c91d7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Mod/Sketcher/Gui/EditModeGeometryCoinManager.cpp
Expand Up @@ -310,7 +310,7 @@ void EditModeGeometryCoinManager::updateGeometryColor(const GeoListFacade & geol
ViewProviderSketchCoinAttorney::executeOnSelectionPointSet(viewProvider,
[pcolor, PtNum, preselectpointmfid, layerId = l, &coinMapping = coinMapping, drawingParameters = this->drawingParameters](const int i) {
auto pointindex = coinMapping.getIndexLayer(i);
if (layerId == pointindex.layerId && pointindex.fieldIndex < PtNum) {
if (layerId == pointindex.layerId && pointindex.fieldIndex >= 0 && pointindex.fieldIndex < PtNum) {
pcolor[pointindex.fieldIndex] = (preselectpointmfid == pointindex)
? drawingParameters.PreselectSelectedColor : drawingParameters.SelectColor;
}
Expand Down

0 comments on commit 86c91d7

Please sign in to comment.