libceph: drop unnecessary check from dispatch() in mon_client.c
authorIlya Dryomov <idryomov@gmail.com>
Mon, 14 Oct 2019 14:25:32 +0000 (16:25 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 25 Nov 2019 10:44:02 +0000 (11:44 +0100)
con->private is set in ceph_con_init() and is never cleared.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
net/ceph/mon_client.c

index 7256c402ebaa32961265d295432df4569fbc6708..9d9e4e4ea600ee08e4cadd8eefb08ad786fe6e65 100644 (file)
@@ -1233,9 +1233,6 @@ static void dispatch(struct ceph_connection *con, struct ceph_msg *msg)
        struct ceph_mon_client *monc = con->private;
        int type = le16_to_cpu(msg->hdr.type);
 
-       if (!monc)
-               return;
-
        switch (type) {
        case CEPH_MSG_AUTH_REPLY:
                handle_auth_reply(monc, msg);