1
0
mirror of https://github.com/clementine-player/Clementine synced 2025-01-09 08:33:29 +01:00
Clementine-audio-player-Mac.../3rdparty/pythonqt/patches/call-slot-returnvalue.patch

22 lines
1.1 KiB
Diff

diff --git a/3rdparty/pythonqt/src/PythonQtSlot.cpp b/3rdparty/pythonqt/src/PythonQtSlot.cpp
index 96f8e8d..43583be 100644
--- a/3rdparty/pythonqt/src/PythonQtSlot.cpp
+++ b/3rdparty/pythonqt/src/PythonQtSlot.cpp
@@ -159,6 +159,7 @@ bool PythonQtCallSlot(PythonQtClassInfo* classInfo, QObject* objectToCall, PyObj
QString e = QString("Called ") + info->fullSignature() + ", return type '" + returnValueParam.name + "' is ignored because it is unknown to PythonQt. Probably you should register it using qRegisterMetaType() or add a default constructor decorator to the class.";
PyErr_SetString(PyExc_ValueError, e.toLatin1().data());
result = NULL;
+ ok = false;
}
}
recursiveEntry--;
@@ -170,7 +171,7 @@ bool PythonQtCallSlot(PythonQtClassInfo* classInfo, QObject* objectToCall, PyObj
*pythonReturnValue = result;
// NOTE: it is important to only return here, otherwise the stack will not be popped!!!
- return result || (directReturnValuePointer && *directReturnValuePointer);
+ return ok;
}
//-----------------------------------------------------------------------------------