call PyErr_Clear() before PyImport_ReloadModule().

This commit is contained in:
Joris Vink 2017-02-22 20:54:57 +01:00
parent 93ab52dcf5
commit e89e644d10
1 changed files with 2 additions and 0 deletions

View File

@ -213,6 +213,8 @@ python_module_reload(struct kore_module *module)
{
PyObject *handle;
PyErr_Clear();
if ((handle = PyImport_ReloadModule(module->handle)) == NULL) {
python_log_error("python_module_reload");
return;