mirror of
https://github.com/parchlinux/calamares.git
synced 2025-02-25 03:15:44 -05:00
Make sure to only call Py_Initialize if Python is not initialized.
This commit is contained in:
parent
553062fc11
commit
0f734c8c5c
1 changed files with 2 additions and 1 deletions
|
@ -189,7 +189,8 @@ Helper::Helper( QObject* parent )
|
|||
// Let's make extra sure we only call Py_Initialize once
|
||||
if ( !s_instance )
|
||||
{
|
||||
Py_Initialize();
|
||||
if ( !Py_IsInitialized() )
|
||||
Py_Initialize();
|
||||
|
||||
m_mainModule = bp::import( "__main__" );
|
||||
m_mainNamespace = m_mainModule.attr( "__dict__" );
|
||||
|
|
Loading…
Add table
Reference in a new issue