X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/mLib-python/blobdiff_plain/5b1830f325c55c70d65fd020f08dd958493e528d..f9d8a4272810eef131b0be8923b93d682bf95937:/fdutils.pyx?ds=sidebyside diff --git a/fdutils.pyx b/fdutils.pyx index 8e5d94a..bb28188 100644 --- a/fdutils.pyx +++ b/fdutils.pyx @@ -34,9 +34,9 @@ def fdflags(file, def fdsend(sock, file, buffer): cdef void *p - cdef int len + cdef Py_ssize_t len cdef int rc - PyObject_AsReadBuffer(buffer, &p, &len) + PyObject_AsReadBuffer(buffer, &p, &len) rc = fdpass_send(_getfd(sock), _getfd(file), p, len) if rc < 0: _oserror() @@ -45,7 +45,7 @@ def fdsend(sock, file, buffer): def fdrecv(sock, unsigned size): cdef void *p cdef buf - cdef int len + cdef Py_ssize_t len cdef PyObject *obj cdef int fd buf = PyString_FromStringAndSize(NULL, size)