Clang complains:
/home/jenkins/workspace/ceph-freebsd/src/test/osdc/object_cacher_stress.cc:50:26: error: ordered comparison between pointer and zero ('std::atomic<unsigned int> *' and 'int')
assert(m_outstanding > 0);
~~~~~~~~~~~~~ ^ ~
/home/jenkins/workspace/ceph-freebsd/src/include/assert.h:117:5: note: expanded from macro 'assert'
((expr) \
^~~~
Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
: m_op(op), m_outstanding(outstanding) {}
void finish(int r) override {
m_op->done++;
- assert(m_outstanding > 0);
- *m_outstanding--;
+ assert(*m_outstanding > 0);
+ (*m_outstanding)--;
}
};