]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
common/options: make mon_clean_pg_upmaps_per_chunk unsigned
authorKefu Chai <kchai@redhat.com>
Wed, 12 Jun 2019 11:44:07 +0000 (19:44 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 13 Jun 2019 05:40:49 +0000 (13:40 +0800)
commita28de7a157e3ee11d2e734ffc005fe4e97a2c1a0
treec61c5028ed231b26106c6967d53c759a2f4d6f37
parent304c791db272a69f589f2828dcd4e1e752222187
common/options: make mon_clean_pg_upmaps_per_chunk unsigned

we don't use a negative number for some different purpose, for instance,
for disabling this option. and this helps to silence following warning:

/home/jenkins-build/build/workspace/ceph-pull-requests/src/mon/OSDMonitor.cc:
In member function 'virtual void
OSDMonitor::encode_pending(MonitorDBStore::TransactionRef)':
/home/jenkins-build/build/workspace/ceph-pull-requests/src/mon/OSDMonitor.cc:1195:31:
warning: comparison of integer expressions of different signedness:
'std::vector<pg_t>::size_type' {aka 'long unsigned int'} and 'int64_t'
{aka 'long int'} [-Wsign-compare]
       if (pgs_to_check.size() < g_conf()->mon_clean_pg_upmaps_per_chunk
* 2) {
           ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/common/legacy_config_opts.h
src/common/options.cc