Fix Py_Logger to raise instances of Exception instead of strings
Raising string exceptions was removed in Python 2.6
This commit is contained in:
parent
76b245e154
commit
0da6fb4d36
1 changed files with 2 additions and 2 deletions
|
|
@ -27,8 +27,8 @@ public:
|
|||
}
|
||||
|
||||
virtual void error(const std::string& msg) {
|
||||
std::string err = "raise \""+msg+"\"";
|
||||
PyRun_SimpleString((char*)err.c_str());
|
||||
std::string err = "raise Exception(\"\"\""+msg+"\"\"\")";
|
||||
PyRun_SimpleString(err.c_str());
|
||||
}
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue