ceph: fix null pointer dereference
authorNathaniel Yazdani <n1ght.4nd.d4y@gmail.com>
Mon, 5 Aug 2013 04:04:30 +0000 (21:04 -0700)
committerSage Weil <sage@inktank.com>
Sat, 10 Aug 2013 00:52:58 +0000 (17:52 -0700)
commitc338c07c51e3106711fad5eb599e375eadb6855d
tree8045873c76f120c3beca96a6db7d8fa316cf3eb2
parent73d9f7eef3d98c3920e144797cc1894c6b005a1e
ceph: fix null pointer dereference

When register_session() is given an out-of-range argument for mds,
ceph_mdsmap_get_addr() will return a null pointer, which would be given to
ceph_con_open() & be dereferenced, causing a kernel oops. This fixes bug #4685
in the Ceph bug tracker <http://tracker.ceph.com/issues/4685>.

Signed-off-by: Nathaniel Yazdani <n1ght.4nd.d4y@gmail.com>
Reviewed-by: Sage Weil <sage@inktank.com>
fs/ceph/mds_client.c