]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mon: MDSMonitor: don't return -EINVAL if function is bool
authorJoao Eduardo Luis <joao@redhat.com>
Fri, 17 Oct 2014 17:01:05 +0000 (18:01 +0100)
committerJoao Eduardo Luis <joao@redhat.com>
Fri, 17 Oct 2014 17:01:05 +0000 (18:01 +0100)
commit91b2a2b69b198567d42f45f75b7f7ea559f89150
treef181f0ee1220bbc29fc9f79e12861d541af90cc8
parent1d1ae413e9f0aafa314af903bcf6b815f6558082
mon: MDSMonitor: don't return -EINVAL if function is bool

Returning -EINVAL on a function that expects bool and the error code to
be in a variable 'r' can only achieve one thing: if this path is ever
touched, instead of returning an error as it was supposed to, we're
returning 'true' with 'r = 0' and, for no apparent reason, the user will
think everything went smoothly but with no new fs created.

Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
src/mon/MDSMonitor.cc