From: azv Date: Wed, 16 Jan 2019 06:55:32 +0000 (+0300) Subject: Fix crash on changing parameters of 'galeries' model. Update model to change business... X-Git-Tag: Jan2019~17 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=ee666c70f6e62251122071d580ffbf8591af826b;p=modules%2Fshaper.git Fix crash on changing parameters of 'galeries' model. Update model to change business parameters. --- diff --git a/src/FeaturesPlugin/FeaturesPlugin_Validators.cpp b/src/FeaturesPlugin/FeaturesPlugin_Validators.cpp index 7e0b51b93..0c9afd4a6 100644 --- a/src/FeaturesPlugin/FeaturesPlugin_Validators.cpp +++ b/src/FeaturesPlugin/FeaturesPlugin_Validators.cpp @@ -1345,9 +1345,12 @@ bool FeaturesPlugin_ValidatorBooleanSmashSelection::isValid( ResultPtr aContext = anAttrSelection->context(); std::shared_ptr aShape = anAttrSelection->value(); - GeomShapePtr aContextShape = aContext->shape(); if (!aShape.get()) { - aShape = aContextShape; + if (!aContext.get()) { + theError = "Error: Empty selection."; + return false; + } + aShape = aContext->shape(); } if (aShape->isSolid() || aShape->isCompSolid()) {