summaryrefslogtreecommitdiffstats
path: root/net/bluetooth/cmtp
diff options
context:
space:
mode:
authorSzymon Janc <szymon.janc@tieto.com>2011-03-21 14:20:03 +0100
committerGustavo F. Padovan <padovan@profusion.mobi>2011-03-31 19:22:56 +0200
commit58aac468be411f2a9b4a28f2ed8e6e2a0db04267 (patch)
tree81538d56c41343bc6b4847004d2e75063d391ff6 /net/bluetooth/cmtp
parentBluetooth: Fix checkpatch errors, code style issues and typos in hidp (diff)
downloadlinux-58aac468be411f2a9b4a28f2ed8e6e2a0db04267.tar.xz
linux-58aac468be411f2a9b4a28f2ed8e6e2a0db04267.zip
Bluetooth: Do not use assignments in IF conditions
Fix checkpatch warnings concerning assignments in if conditions. Signed-off-by: Szymon Janc <szymon.janc@tieto.com> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
Diffstat (limited to 'net/bluetooth/cmtp')
-rw-r--r--net/bluetooth/cmtp/core.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/net/bluetooth/cmtp/core.c b/net/bluetooth/cmtp/core.c
index 964ea9126f9f..16aa6bd039ba 100644
--- a/net/bluetooth/cmtp/core.c
+++ b/net/bluetooth/cmtp/core.c
@@ -235,9 +235,12 @@ static void cmtp_process_transmit(struct cmtp_session *session)
size = min_t(uint, ((tail < 258) ? (tail - 2) : (tail - 3)), skb->len);
- if ((scb->id < 0) && ((scb->id = cmtp_alloc_block_id(session)) < 0)) {
- skb_queue_head(&session->transmit, skb);
- break;
+ if (scb->id < 0) {
+ scb->id = cmtp_alloc_block_id(session);
+ if (scb->id < 0) {
+ skb_queue_head(&session->transmit, skb);
+ break;
+ }
}
if (size < 256) {