From: Kefu Chai Date: Thu, 3 Dec 2020 08:04:19 +0000 (+0800) Subject: pybind/rgw: s/bool/bint/ X-Git-Tag: v17.0.0~356^2~9 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=a05f62428818f10bc9600f22d28f8157bd541d0e;p=ceph.git pybind/rgw: s/bool/bint/ when compile a pure python cythonized binding, bool is not defined because, i think, Cython does not include by default. so use bint indead. Signed-off-by: Kefu Chai --- diff --git a/src/pybind/rgw/rgw.pyx b/src/pybind/rgw/rgw.pyx index 3385d063e810b..123c57d2ee009 100644 --- a/src/pybind/rgw/rgw.pyx +++ b/src/pybind/rgw/rgw.pyx @@ -5,7 +5,6 @@ This module is a thin wrapper around rgw_file. from cpython cimport PyObject, ref, exc, array from libc.stdint cimport * -from libcpp cimport bool from libc.stdlib cimport malloc, realloc, free from cstat cimport stat @@ -163,7 +162,7 @@ cdef make_ex(ret, msg): return Error(msg + (": error code %d" % ret)) -cdef bool readdir_cb(const char *name, void *arg, uint64_t offset, stat *st, uint32_t st_mask, uint32_t flags) \ +cdef bint readdir_cb(const char *name, void *arg, uint64_t offset, stat *st, uint32_t st_mask, uint32_t flags) \ except? -9000 with gil: if exc.PyErr_Occurred(): return False @@ -371,7 +370,7 @@ cdef class LibRGWFS(object): cdef: rgw_file_handle *_dir_handler = dir_handler.handler uint64_t _offset = offset - bool _eof + bint _eof uint32_t _flags = flags with nogil: ret = rgw_readdir(self.fs, _dir_handler, &_offset, &readdir_cb,