]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw/file: change function signature to match the one generated by cython 48828/head
authoryuval Lifshitz <ylifshit@redhat.com>
Thu, 10 Nov 2022 13:21:56 +0000 (15:21 +0200)
committeryuval Lifshitz <ylifshit@redhat.com>
Thu, 10 Nov 2022 13:21:56 +0000 (15:21 +0200)
without this change, clang16 fails to compile,
due to conversion from "bool" to "int".
see error: https://paste.sh/QybPVNdh#OtffZeqJKcsqUVMupPYD11Kl

Signed-off-by: yuval Lifshitz <ylifshit@redhat.com>
src/include/rados/rgw_file.h
src/test/librgw_file.cc
src/test/librgw_file_gp.cc
src/test/librgw_file_marker.cc
src/test/librgw_file_nfsns.cc

index eb2d6dc4d82ea8df4a26274d01ea05d1e7db4276..e1ea4559323b55b02f2668eeebd468ab0820731e 100644 (file)
@@ -221,7 +221,7 @@ int rgw_unlink(struct rgw_fs *rgw_fs,
 /*
     read  directory content
 */
-typedef bool (*rgw_readdir_cb)(const char *name, void *arg, uint64_t offset,
+typedef int (*rgw_readdir_cb)(const char *name, void *arg, uint64_t offset,
                               struct stat *st, uint32_t mask,
                               uint32_t flags);
 
index 328c42e6f075eba9da51e1aeb30466e2fafe5348..8f50ab7ac192a5fe95eb437e174a4a2e9664dcac 100644 (file)
@@ -73,7 +73,7 @@ TEST(LibRGW, GETATTR_ROOT) {
 }
 
 extern "C" {
-  static bool r1_cb(const char* name, void *arg, uint64_t offset,
+  static int r1_cb(const char* name, void *arg, uint64_t offset,
                    struct stat* st, uint32_t st_mask,
                    uint32_t flags) {
     // don't need arg--it would point to fids1
@@ -137,7 +137,7 @@ TEST(LibRGW, GETATTR_BUCKETS) {
 }
 
 extern "C" {
-  static bool r2_cb(const char* name, void *arg, uint64_t offset,
+  static int r2_cb(const char* name, void *arg, uint64_t offset,
                    struct stat* st, uint32_t st_mask,
                    uint32_t flags) {
     std::vector<fid_type>& obj_vector = *(static_cast<std::vector<fid_type>*>(arg));
index 56b61dce4be8e2ea1c4fd80728741b713f85b1b8..4c4cfaa61b11d72a374ba02ae64d02d05bf04738 100644 (file)
@@ -213,7 +213,7 @@ TEST(LibRGW, LOOKUP_BUCKET) {
 }
 
 extern "C" {
-  static bool r2_cb(const char* name, void *arg, uint64_t offset,
+  static int r2_cb(const char* name, void *arg, uint64_t offset,
                    struct stat *st, uint32_t st_mask,
                    uint32_t flags) {
     // don't need arg--it would point to fids
index 9095fd9bfcf2ab617e831eb8548e6a7f2cf5677a..796410297015771a1c3cde2d83734d0b02e4b485 100644 (file)
@@ -292,7 +292,7 @@ TEST(LibRGW, MARKER1_SETUP_OBJECTS)
 }
 
 extern "C" {
-  static bool r2_cb(const char* name, void *arg, uint64_t offset,
+  static int r2_cb(const char* name, void *arg, uint64_t offset,
                    struct stat* st, uint32_t st_mask,
                    uint32_t flags) {
     dirent_vec& dvec =
index 2ce65519c017f12e945a35e5c80be73184ada1bd..5fe69d81e4759adf7eda13dba33350801cbc7c2d 100644 (file)
@@ -873,7 +873,7 @@ TEST(LibRGW, RELEASE_DIRS1) {
 }
 
 extern "C" {
-  static bool r1_cb(const char* name, void *arg, uint64_t offset,
+  static int r1_cb(const char* name, void *arg, uint64_t offset,
                    struct stat* st, uint32_t st_mask,
                    uint32_t flags) {
     struct rgw_file_handle* parent_fh
@@ -1031,7 +1031,7 @@ TEST(LibRGW, MARKER1_SETUP_OBJECTS)
 }
 
 extern "C" {
-  static bool r2_cb(const char* name, void *arg, uint64_t offset,
+  static int r2_cb(const char* name, void *arg, uint64_t offset,
                    struct stat* st, uint32_t st_mask,
                    uint32_t flags) {
     dirent_vec& dvec =