]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
tools/osdmaptool: mark unused variable [[maybe_unused]] 40840/head
authorKefu Chai <kchai@redhat.com>
Wed, 14 Apr 2021 02:46:14 +0000 (10:46 +0800)
committerKefu Chai <kchai@redhat.com>
Wed, 14 Apr 2021 03:11:08 +0000 (11:11 +0800)
commite2875647b847f948367b22a493362c8398bd40fa
tree427094a80194c6a0a565b3503229d6e98b5d4e51
parentdcd90a1c8d789d0f1ebea06f88d69096c5ea884a
tools/osdmaptool: mark unused variable [[maybe_unused]]

to silence warning from GCC when performing release build, like:

../src/tools/osdmaptool.cc: In function ‘int main(int, const char**)’:
../src/tools/osdmaptool.cc:472:9: warning: variable ‘r’ set but not used [-Wunused-but-set-variable]
  472 |     int r = clock_gettime(CLOCK_MONOTONIC, &round_start);
      |         ^

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/tools/osdmaptool.cc