From: Sage Weil Date: Tue, 4 Feb 2014 05:12:41 +0000 (-0800) Subject: client: fix warnings X-Git-Tag: v0.78~227^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=60ca6f699b8fac987c95f939b9e0b92be233240b;p=ceph.git client: fix warnings client/Client.cc: In member function 'int Client::_read(Fh*, int64_t, uint64_t, ceph::bufferlist*)': warning: client/Client.cc:5893:27: comparison between signed and unsigned integer expressions [-Wsign-compare] client/Client.cc: In member function 'int Client::_write(Fh*, int64_t, uint64_t, const char*)': warning: client/Client.cc:6235:30: comparison between signed and unsigned integer expressions [-Wsign-compare] Signed-off-by: Sage Weil --- diff --git a/src/client/Client.cc b/src/client/Client.cc index c2a1757b2af6..d7d9a507d3ea 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -5890,7 +5890,7 @@ int Client::_read(Fh *f, int64_t offset, uint64_t size, bufferlist *bl) bl->substr_of(in->inline_data, offset, len - offset); bl->append_zero(endoff - len); } - } else if (offset < endoff) { + } else if ((uint64_t)offset < endoff) { bl->append_zero(endoff - offset); } diff --git a/src/common/config_opts.h b/src/common/config_opts.h index 80828c5708be..41fc9e1ea6fe 100644 --- a/src/common/config_opts.h +++ b/src/common/config_opts.h @@ -263,7 +263,7 @@ OPTION(client_oc_max_dirty_age, OPT_DOUBLE, 5.0) // max age in cache before OPTION(client_oc_max_objects, OPT_INT, 1000) // max objects in cache OPTION(client_debug_force_sync_read, OPT_BOOL, false) // always read synchronously (go to osds) OPTION(client_debug_inject_tick_delay, OPT_INT, 0) // delay the client tick for a number of seconds -OPTION(client_max_inline_size, OPT_INT, 4096) +OPTION(client_max_inline_size, OPT_U64, 4096) // note: the max amount of "in flight" dirty data is roughly (max - target) OPTION(fuse_use_invalidate_cb, OPT_BOOL, false) // use fuse 2.8+ invalidate callback to keep page cache consistent OPTION(fuse_allow_other, OPT_BOOL, true)