]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/osdmonitor: _have_pending_crush of return value should be bool 7800/head
authorhuanwen ren <ren.huanwen@zte.com.cn>
Fri, 29 Apr 2016 02:53:14 +0000 (10:53 +0800)
committerhuanwen ren <ren.huanwen@zte.com.cn>
Fri, 29 Apr 2016 02:53:14 +0000 (10:53 +0800)
have_pending_crush of return value should be bool, fix it

Signed-off-by: huanwen ren <ren.huanwen@zte.com.cn>
src/mon/OSDMonitor.cc

index 42c58a0111adcdeac39f947f4e3b57dbb5645a10..95fb11fc0490e9d1cab42e8939ec7d5ee1200f50 100644 (file)
@@ -83,7 +83,7 @@ OSDMonitor::OSDMonitor(CephContext *cct, Monitor *mn, Paxos *p, const string& se
 
 bool OSDMonitor::_have_pending_crush()
 {
-  return pending_inc.crush.length();
+  return pending_inc.crush.length() > 0;
 }
 
 CrushWrapper &OSDMonitor::_get_stable_crush()