aboutsummaryrefslogtreecommitdiffstats
path: root/net/bluetooth
diff options
context:
space:
mode:
authorJoão Paulo Rechi Vita <jprvita@profusion.mobi>2010-06-22 13:56:25 -0300
committerMarcel Holtmann <marcel@holtmann.org>2010-07-21 10:39:10 -0700
commitbc766db2ef3700ae74bdfc88d74b771b97971a24 (patch)
tree0f9fcdb66a2660168e154c8ff17cbf32ac9a47e0 /net/bluetooth
parentf9dd11b03c5c3cd6bdf2e503400bbc922c898974 (diff)
downloadkernel_samsung_espresso10-bc766db2ef3700ae74bdfc88d74b771b97971a24.zip
kernel_samsung_espresso10-bc766db2ef3700ae74bdfc88d74b771b97971a24.tar.gz
kernel_samsung_espresso10-bc766db2ef3700ae74bdfc88d74b771b97971a24.tar.bz2
Bluetooth: Fix error return value on sendmsg.
When the socket is in a bad state EBADFD is more appropriate then EINVAL. Signed-off-by: João Paulo Rechi Vita <jprvita@profusion.mobi> Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net/bluetooth')
-rw-r--r--net/bluetooth/l2cap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/bluetooth/l2cap.c b/net/bluetooth/l2cap.c
index 884b840..ac25952 100644
--- a/net/bluetooth/l2cap.c
+++ b/net/bluetooth/l2cap.c
@@ -1881,7 +1881,7 @@ static int l2cap_sock_sendmsg(struct kiocb *iocb, struct socket *sock, struct ms
default:
BT_DBG("bad state %1.1x", pi->mode);
- err = -EINVAL;
+ err = -EBADFD;
}
done: