[OTHER] Catch only Exception, not BaseException
This commit is contained in:
@@ -828,7 +828,7 @@ Py::Object PySideUicModule::loadUiType(const Py::Tuple& args)
|
||||
<< "import xml.etree.ElementTree as xml\n"
|
||||
<< "try:\n"
|
||||
<< " from cStringIO import StringIO\n"
|
||||
<< "except:\n"
|
||||
<< "except Exception:\n"
|
||||
<< " from io import StringIO\n"
|
||||
<< "\n"
|
||||
<< "uiFile = \"" << file.c_str() << "\"\n"
|
||||
@@ -850,7 +850,7 @@ Py::Object PySideUicModule::loadUiType(const Py::Tuple& args)
|
||||
<< "import xml.etree.ElementTree as xml\n"
|
||||
<< "try:\n"
|
||||
<< " from cStringIO import StringIO\n"
|
||||
<< "except:\n"
|
||||
<< "except Exception:\n"
|
||||
<< " from io import StringIO\n"
|
||||
<< "\n"
|
||||
<< "uiFile = \"" << file.c_str() << "\"\n"
|
||||
|
||||
Reference in New Issue
Block a user