diff options
Diffstat (limited to 'src/if_py_both.h')
-rw-r--r-- | src/if_py_both.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/if_py_both.h b/src/if_py_both.h index e2f4857e4..1ad7dc616 100644 --- a/src/if_py_both.h +++ b/src/if_py_both.h @@ -476,16 +476,18 @@ AlwaysNone(PyObject *self UNUSED) AlwaysFalse(PyObject *self UNUSED) { /* do nothing */ - Py_INCREF(Py_False); - return Py_False; + PyObject *ret = Py_False; + Py_INCREF(ret); + return ret; } static PyObject * AlwaysTrue(PyObject *self UNUSED) { /* do nothing */ - Py_INCREF(Py_True); - return Py_True; + PyObject *ret = Py_True; + Py_INCREF(ret); + return ret; } /***************/ |