Bluetooth: Refuse peer RFCOMM address reading when not connected
authorJohan Hedberg <johan.hedberg@intel.com>
Tue, 28 Jan 2014 23:16:50 +0000 (15:16 -0800)
committerJohan Hedberg <johan.hedberg@intel.com>
Thu, 13 Feb 2014 07:51:39 +0000 (09:51 +0200)
commit35364c99d20edc7329843e2a6dad6851d77eafd7
tree2710e8fc985f8af341fa03a2c6d86dfc75ed9433
parentb783fbc3a55691f978b9f78d552a0d7e7d2705ad
Bluetooth: Refuse peer RFCOMM address reading when not connected

When we're not connected the peer address information is undefined. This
patch fixes the remote address getting to return a proper error in case
the sate is anything else than BT_CONNECTED.

Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
net/bluetooth/rfcomm/sock.c