From: Ovidiu Mircescu Date: Fri, 21 Apr 2017 13:33:38 +0000 (+0200) Subject: Python is no longer initialized by YACSEvalSession. X-Git-Tag: V8_3_0rc3^2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=2dc005a0159955ef19d5ecd547446c9f9c482e51;p=modules%2Fyacs.git Python is no longer initialized by YACSEvalSession. Python initialization has to be done outside the YACSevalYFX lib. --- diff --git a/src/evalyfx/YACSEvalSession.cxx b/src/evalyfx/YACSEvalSession.cxx index 3a91c4e2f..d08aa9c49 100644 --- a/src/evalyfx/YACSEvalSession.cxx +++ b/src/evalyfx/YACSEvalSession.cxx @@ -36,13 +36,8 @@ const char YACSEvalSession::NSPORT_VAR_NAME[]="NSPORT"; YACSEvalSession::YACSEvalSession():_isAttached(false),_isLaunched(false),_isForcedPyThreadSaved(false),_port(-1),_salomeInstanceModule(0),_salomeInstance(0),_internal(new YACSEvalSessionInternal) { - if(!Py_IsInitialized()) - Py_Initialize(); - // - { - YACS::ENGINE::AutoGIL gal; - _salomeInstanceModule=PyImport_ImportModule(const_cast("salome_instance")); - } + YACS::ENGINE::AutoGIL gal; + _salomeInstanceModule=PyImport_ImportModule(const_cast("salome_instance")); } YACSEvalSession::~YACSEvalSession()