Skip to content

Commit

Permalink
Path: [skip ci] fix Python 3.9 deprecation warning
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Dec 23, 2020
1 parent ed0a5af commit d89cd95
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Mod/Path/App/VoronoiPyImp.cpp
Expand Up @@ -185,7 +185,11 @@ static bool callbackWithVertex(Voronoi::diagram_type *dia, PyObject *callback, c
#endif
PyObject *vx = new VoronoiVertexPy(new VoronoiVertex(dia, v));
PyObject *arglist = Py_BuildValue("(O)", vx);
#if PY_VERSION_HEX < 0x03090000
PyObject *result = PyEval_CallObject(callback, arglist);
#else
PyObject *result = PyObject_CallObject(callback, arglist);
#endif
Py_DECREF(arglist);
Py_DECREF(vx);
if (result == NULL) {
Expand Down

0 comments on commit d89cd95

Please sign in to comment.