aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside6/PySide6/glue/qtcore.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'sources/pyside6/PySide6/glue/qtcore.cpp')
-rw-r--r--sources/pyside6/PySide6/glue/qtcore.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/sources/pyside6/PySide6/glue/qtcore.cpp b/sources/pyside6/PySide6/glue/qtcore.cpp
index 6d51f337f..a687d8447 100644
--- a/sources/pyside6/PySide6/glue/qtcore.cpp
+++ b/sources/pyside6/PySide6/glue/qtcore.cpp
@@ -1920,7 +1920,7 @@ auto callback = [callable]() -> void
return;
}
Shiboken::GilState state;
- PyObject_CallObject(callable, nullptr);
+ Shiboken::AutoDecRef ret(PyObject_CallObject(callable, nullptr));
Py_DECREF(callable);
};
Py_INCREF(callable);
@@ -2007,9 +2007,9 @@ auto callback = [callable, count, arg_qpermission](const QPermission &permission
if (arg_qpermission) {
Shiboken::AutoDecRef arglist(PyTuple_New(1));
PyTuple_SET_ITEM(arglist.object(), 0, %CONVERTTOPYTHON[QPermission](permission));
- PyObject_CallObject(callable, arglist);
+ Shiboken::AutoDecRef ret(PyObject_CallObject(callable, arglist));
} else {
- PyObject_CallObject(callable, nullptr);
+ Shiboken::AutoDecRef ret(PyObject_CallObject(callable, nullptr));
}
Py_DECREF(callable);
};