]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
log/Log: cast parameter of syslog() from unsigned to int
authorKefu Chai <kchai@redhat.com>
Mon, 16 Nov 2020 07:18:33 +0000 (15:18 +0800)
committerKefu Chai <kchai@redhat.com>
Mon, 16 Nov 2020 07:38:26 +0000 (15:38 +0800)
commit7ba8a611e92688abaa55001a9e59d13e55b32d78
treed52706fdf85bbfae17e4ac674cf0088249976d25
parentc39590ba408faf776ee21d6d3b796092145655ce
log/Log: cast parameter of syslog() from unsigned to int

silences warning like:

../src/log/Log.cc:325:34: warning: field precision should have type 'int', but argument has type 'std::basic_string_view::size_type' (aka 'unsigned long') [-Wformat]
    syslog(LOG_USER|LOG_INFO, "%.*s", s.size(), s.data());
                               ~~^~   ~~~~~~~~
1 warning generated.

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