Commit 98cfda81 authored by Chengguang Xu's avatar Chengguang Xu Committed by Ilya Dryomov

ceph: return proper bool type to caller instead of pointer

Change to return true/false only for bool type return code.
Signed-off-by: default avatarChengguang Xu <cgxu519@gmx.com>
Reviewed-by: default avatar"Yan, Zheng" <zyan@redhat.com>
Signed-off-by: default avatarIlya Dryomov <idryomov@gmail.com>
parent bb48bd4d
......@@ -419,9 +419,10 @@ struct ceph_mds_session *__ceph_lookup_mds_session(struct ceph_mds_client *mdsc,
static bool __have_session(struct ceph_mds_client *mdsc, int mds)
{
if (mds >= mdsc->max_sessions)
if (mds >= mdsc->max_sessions || !mdsc->sessions[mds])
return false;
return mdsc->sessions[mds];
else
return true;
}
static int __verify_registered_session(struct ceph_mds_client *mdsc,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment