提交 33aa96e7 编写于 作者: S Sage Weil

crush: always return a value from crush_bucket_choose

Even when we encounter a corrupt bucket.  We still BUG().  This fixes
the warning

fs/ceph/crush/mapper.c: In function 'crush_choose':
fs/ceph/crush/mapper.c:352: warning: control may reach end of non-void function
'crush_bucket_choose' being inlined
Signed-off-by: NSage Weil <sage@newdream.net>
上级 63ff78b2
......@@ -253,7 +253,7 @@ static int crush_bucket_choose(struct crush_bucket *in, int x, int r)
x, r);
default:
BUG_ON(1);
/* return in->items[0] */;
return in->items[0];
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册