Skip to content

Commit

Permalink
Replace PyEval_CallObject with PyObject_Call
Browse files Browse the repository at this point in the history
  • Loading branch information
luciansmith committed Oct 24, 2024
1 parent 0a0b728 commit d00e9e0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions wrappers/Python/roadrunner/PyEventListener.h
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ class PyEventListener : public EventListener
*/

PyObject *args = Py_BuildValue("(N, i, s)", pyModel, index, eventId.c_str());
PyObject *pyres = PyEval_CallObject(pyOnTrigger, args);
PyObject *pyres = PyObject_Call(pyOnTrigger, args, NULL);


if (PyErr_Occurred()) {
Expand Down Expand Up @@ -170,7 +170,7 @@ class PyEventListener : public EventListener

PyObject *pyModel = ExecutableModel_NewPythonObj(model);
PyObject *args = Py_BuildValue("(N, i, s)", pyModel, index, eventId.c_str());
PyObject *pyres = PyEval_CallObject(pyOnAssignment, args);
PyObject *pyres = PyObject_Call(pyOnAssignment, args, NULL);

if (PyErr_Occurred()) {

Expand Down

0 comments on commit d00e9e0

Please sign in to comment.