OSDCaps: fix allow_all()

OSD_CAP_ANY is not a mask. Treating it as one made any allowance
equivalent to 'allow *'.

Fixes: #3228
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
This commit is contained in:
Josh Durgin 2012-09-27 14:44:57 -07:00
parent e903ca7add
commit de6e0d8112

View File

@ -50,7 +50,7 @@ struct OSDCapSpec {
OSDCapSpec(std::string n, std::string a) : allow(0), class_name(n), class_allow(a) {}
bool allow_all() const {
return allow & OSD_CAP_ANY;
return allow == OSD_CAP_ANY;
}
};