From: John Spray Date: Tue, 26 Aug 2014 11:52:38 +0000 (+0100) Subject: include/CompatSet: more const-ness X-Git-Tag: v0.86~152^2~7 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=124856ab58f37c82f538ac1eba63be14218c590f;p=ceph.git include/CompatSet: more const-ness Signed-off-by: John Spray --- diff --git a/src/include/CompatSet.h b/src/include/CompatSet.h index 583c3dd3325..0019ebdb059 100644 --- a/src/include/CompatSet.h +++ b/src/include/CompatSet.h @@ -120,13 +120,13 @@ struct CompatSet { /* does this filesystem implementation have the features required to read the other? */ - bool readable(CompatSet& other) { + bool readable(CompatSet const& other) const { return !((other.incompat.mask ^ incompat.mask) & other.incompat.mask); } /* does this filesystem implementation have the features required to write the other? */ - bool writeable(CompatSet& other) { + bool writeable(CompatSet const& other) const { return readable(other) && !((other.ro_compat.mask ^ ro_compat.mask) & other.ro_compat.mask); }