diff options
author | Michele Calgaro <[email protected]> | 2024-04-11 09:35:33 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2024-04-11 20:52:23 +0900 |
commit | 431aa14fbefd8dfd46c4b4f47f241f03f2c623b8 (patch) | |
tree | 0acd38c041eaa9575a3ae182382bdc1ace5af372 | |
parent | a0a0ac290ef97af13797a33bae01a5abde3c6825 (diff) | |
download | sip4-tqt-431aa14fbefd8dfd46c4b4f47f241f03f2c623b8.tar.gz sip4-tqt-431aa14fbefd8dfd46c4b4f47f241f03f2c623b8.zip |
Fix FTBFS described in issue #19
Signed-off-by: Michele Calgaro <[email protected]>
-rw-r--r-- | siplib/siplib.c | 12 | ||||
-rw-r--r-- | siplib/tqtlib.c | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/siplib/siplib.c b/siplib/siplib.c index b891f79..f2ac7be 100644 --- a/siplib/siplib.c +++ b/siplib/siplib.c @@ -7488,7 +7488,7 @@ static int compareTypeDef(const void *key, const void *el) /* Find which external type it is. */ while (etd->et_nr >= 0) { - const sipTypeDef **tdp = &module_searched->em_types[etd->et_nr]; + const sipTypeDef **tdp = (const sipTypeDef**)&module_searched->em_types[etd->et_nr]; if (tdp == (const sipTypeDef **)el) { @@ -8485,9 +8485,9 @@ static void sipSimpleWrapper_releasebuffer(sipSimpleWrapper *self, const sipClassTypeDef *ctd; if ((ptr = getPtrTypeDef(self, &ctd)) == NULL) - return -1; + return; - return ctd->ctd_releasebuffer((PyObject *)self, ptr, buf); + ctd->ctd_releasebuffer((PyObject *)self, ptr, buf); } @@ -9762,7 +9762,7 @@ static int convertToWCharArray(PyObject *obj, wchar_t **ap, SIP_SSIZE_T *aszp) if ((wc = sip_api_malloc(ulen * sizeof (wchar_t))) == NULL) return -1; - ulen = PyUnicode_AsWideChar((PyUnicodeObject *)obj, wc, ulen); + ulen = PyUnicode_AsWideChar(obj, wc, ulen); if (ulen < 0) { @@ -9797,7 +9797,7 @@ static int convertToWChar(PyObject *obj, wchar_t *ap) if (PyUnicode_GET_LENGTH(obj) != 1) return -1; - if (PyUnicode_AsWideChar((PyUnicodeObject *)obj, ap, 1) != 1) + if (PyUnicode_AsWideChar(obj, ap, 1) != 1) return -1; return 0; @@ -9837,7 +9837,7 @@ static int convertToWCharString(PyObject *obj, wchar_t **ap) if ((wc = sip_api_malloc((ulen + 1) * sizeof (wchar_t))) == NULL) return -1; - ulen = PyUnicode_AsWideChar((PyUnicodeObject *)obj, wc, ulen); + ulen = PyUnicode_AsWideChar(obj, wc, ulen); if (ulen < 0) { diff --git a/siplib/tqtlib.c b/siplib/tqtlib.c index df35d6c..d59c138 100644 --- a/siplib/tqtlib.c +++ b/siplib/tqtlib.c @@ -143,7 +143,7 @@ PyObject *sip_api_invoke_slot(const sipSlot *slot, PyObject *sigargs) * longer exists. */ if (PyObject_TypeCheck(self, (PyTypeObject *)&sipSimpleWrapper_Type) && - sip_api_get_address(self) == NULL) + sip_api_get_address((sipSimpleWrapper *)self) == NULL) { Py_XDECREF(sref); |