From: mpv Date: Mon, 15 Jan 2018 13:52:44 +0000 (+0300) Subject: Fixed the Linux compilation X-Git-Tag: V_3.0.0RC1~34 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=82a9c047c3a7e1b50243aeed5c39f99041fcafc7;p=modules%2Fshaper.git Fixed the Linux compilation --- diff --git a/src/Model/Model_AttributeSelection.cpp b/src/Model/Model_AttributeSelection.cpp index ad18492ce..7c86500cd 100644 --- a/src/Model/Model_AttributeSelection.cpp +++ b/src/Model/Model_AttributeSelection.cpp @@ -887,8 +887,11 @@ void Model_AttributeSelection::selectSubShape( ResultCompSolidPtr aCompContext = ModelAPI_Tools::compSolidOwner(aCont); int aSubsSize = (aCompContext.get() ? aCompContext->numberOfSubs() : 0) + 1; for(int aResultNum = 0; aResultNum < aSubsSize; aResultNum++) { - ResultPtr aResCont = aCompContext.get() ? (aResultNum == aSubsSize - 1 ? - aCompContext : aCompContext->subResult(aResultNum)) : aCont; + ResultPtr aResCont = aCont; + if (aCompContext.get()) + if (aResultNum == aSubsSize - 1) + aResCont = aCompContext; + else aResCont = aCompContext->subResult(aResultNum); const std::set& aRefs = aResCont->data()->refsToMe(); std::set::const_iterator aRef = aRefs.begin(); for(; !aFindNewContext && aRef != aRefs.end(); aRef++) {