diff options
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/pychrysalide/pychrysa.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/plugins/pychrysalide/pychrysa.c b/plugins/pychrysalide/pychrysa.c index f998b67..9f0bc20 100644 --- a/plugins/pychrysalide/pychrysa.c +++ b/plugins/pychrysalide/pychrysa.c @@ -833,13 +833,18 @@ G_MODULE_EXPORT void chrysalide_plugin_exit(GPluginModule *plugin) G_MODULE_EXPORT void chrysalide_plugin_on_native_loaded(GPluginModule *plugin, PluginAction action) { + PyThreadState *tstate; /* Contexte d'environnement */ + if (!_standalone) - PyEval_AcquireLock(); + { + tstate = get_pychrysalide_main_tstate(); + PyEval_RestoreThread(tstate); + } load_python_plugins(plugin); if (!_standalone) - PyEval_ReleaseLock(); + PyEval_SaveThread(); } |