We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 170f855 commit e258226Copy full SHA for e258226
1 file changed
bindings/solv.i
@@ -44,11 +44,11 @@ typedef struct {
44
#if defined(SWIGPYTHON)
45
const void *pybuf = 0;
46
Py_ssize_t pysize = 0;
47
-#if PY_VERSION_HEX >= 0x03000000
48
- res = PyBytes_AsStringAndSize($input, &pybuf, &pysize);
49
-#else
+%#if PY_VERSION_HEX >= 0x03000000
+ res = PyBytes_AsStringAndSize($input, (char **)&pybuf, &pysize);
+%#else
50
res = PyObject_AsReadBuffer($input, &pybuf, &pysize);
51
-#endif
+%#endif
52
if (res < 0) {
53
%argument_fail(res, "BinaryBlob", $symname, $argnum);
54
} else {
0 commit comments