diff options
author | Sage Weil <sage@inktank.com> | 2013-07-19 21:48:26 -0700 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-07-19 22:32:23 -0700 |
commit | 675d783aedc744fd0ad17e2df4d53bbf51d76b12 (patch) | |
tree | 015d00eeeabe937b087f0a67ecde1dd6646afc93 /src/mon/Monitor.cc | |
parent | f79d96504973134b36985e152cb0badaceac3ed4 (diff) | |
download | ceph-675d783aedc744fd0ad17e2df4d53bbf51d76b12.tar.gz |
mon/MonCap: simplify rwx match logic
Make this a positive check instead of double negative.
Signed-off-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'src/mon/Monitor.cc')
-rw-r--r-- | src/mon/Monitor.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mon/Monitor.cc b/src/mon/Monitor.cc index 8b38adf449d..7e484e8db6b 100644 --- a/src/mon/Monitor.cc +++ b/src/mon/Monitor.cc @@ -1523,8 +1523,10 @@ bool Monitor::_allowed_command(MonSession *s, map<string, cmd_vartype>& cmd) { bool retval = false; - if (s->caps.is_allow_all()) + if (s->caps.is_allow_all()) { + dout(10) << __func__ << " allow_all" << dendl; return true; + } string prefix; cmd_getval(g_ceph_context, cmd, "prefix", prefix); @@ -1542,6 +1544,7 @@ bool Monitor::_allowed_command(MonSession *s, map<string, cmd_vartype>& cmd) retval = true; } + dout(10) << __func__ << " = " << retval << dendl; return retval; } |