diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-01-19 23:34:11 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-01-19 23:34:11 +0900 |
| commit | 1c362264d328c8886d33061ab992750741f7933a (patch) | |
| tree | c56b482a6539c2992c97f3fe1bcb4d8ec46ef53f /sip/qt/qiodevice.sip | |
| parent | 6054548c2546819cb0413bf6438087f5fe8f4ab4 (diff) | |
| download | pytqt-1c362264d328c8886d33061ab992750741f7933a.tar.gz pytqt-1c362264d328c8886d33061ab992750741f7933a.zip | |
Remove/replace old conditional python code.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'sip/qt/qiodevice.sip')
| -rw-r--r-- | sip/qt/qiodevice.sip | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sip/qt/qiodevice.sip b/sip/qt/qiodevice.sip index 75ba7dc..30ca235 100644 --- a/sip/qt/qiodevice.sip +++ b/sip/qt/qiodevice.sip @@ -139,7 +139,7 @@ public: } else { - sipRes = SIPBytes_FromStringAndSize(buf,actlen); + sipRes = PyBytes_FromStringAndSize(buf,actlen); sipFree((void *)buf); @@ -159,15 +159,15 @@ public: if (buf == Py_None) sipRes = -1L; - else if (!SIPBytes_Check(buf)) + else if (!PyBytes_Check(buf)) { sipBadCatcherResult(sipMethod); sipIsErr = 1; } else { - memcpy(a0,SIPBytes_AS_STRING(buf),SIPBytes_GET_SIZE(buf)); - sipRes = SIPBytes_GET_SIZE(buf); + memcpy(a0,PyBytes_AS_STRING(buf),PyBytes_GET_SIZE(buf)); + sipRes = PyBytes_GET_SIZE(buf); } Py_DECREF(buf); @@ -201,7 +201,7 @@ public: } else { - sipRes = SIPBytes_FromStringAndSize(buf,actlen); + sipRes = PyBytes_FromStringAndSize(buf,actlen); sipFree((void *)buf); @@ -221,15 +221,15 @@ public: if (buf == Py_None) sipRes = -1L; - else if (!SIPBytes_Check(buf)) + else if (!PyBytes_Check(buf)) { sipBadCatcherResult(sipMethod); sipIsErr = 1; } else { - memcpy(a0,SIPBytes_AS_STRING(buf),SIPBytes_GET_SIZE(buf)); - sipRes = SIPBytes_GET_SIZE(buf); + memcpy(a0,PyBytes_AS_STRING(buf),PyBytes_GET_SIZE(buf)); + sipRes = PyBytes_GET_SIZE(buf); } Py_DECREF(buf); |
