silences warning like:
../src/cls/fifo/cls_fifo.cc: In member function ‘int rados::cls::fifo::{anonymous}::EntryReader::get_next_entry(ceph::buffer::v15_2_0::list*, uint64_t*, ceph::real_time*)’:
../src/include/rados/objclass.h:33:18: warning: format ‘%llu’ expects argument of type ‘long long unsigned int’, but argument 7 has type ‘ceph_le64’ {aka ‘ceph_le<long long unsigned int>’} [-Wformat=]
33 | cls_log(level, "<cls> %s:%d: " fmt, __FILE__, __LINE__, ##__VA_ARGS__)
../src/include/rados/objclass.h:33:18: note: in definition of macro ‘CLS_LOG’
33 | cls_log(level, "<cls> %s:%d: " fmt, __FILE__, __LINE__, ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~
../src/cls/fifo/cls_fifo.cc:703:48: note: format string is defined here
703 | CLS_LOG(10, "%s():%d: pre_header.pre_size=%llu", __func__, __LINE__,
| ~~~^
| |
| long long unsigned int
Signed-off-by: Kefu Chai <kchai@redhat.com>
*pofs = ofs;
}
- CLS_LOG(10, "%s():%d: pre_header.pre_size=%llu", __func__, __LINE__,
- pre_header.pre_size);
+ CLS_LOG(10, "%s():%d: pre_header.pre_size=%" PRIu64, __func__, __LINE__,
+ uint64_t(pre_header.pre_size));
r = seek(pre_header.pre_size);
if (r < 0) {
CLS_ERR("ERROR: %s(): failed to seek: r=%d", __func__, r);