]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[BLUETOOTH] hci_sysfs.c: Kill build warning.
authorDavid S. Miller <davem@davemloft.net>
Mon, 18 Feb 2008 08:20:50 +0000 (00:20 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 18 Feb 2008 08:20:50 +0000 (00:20 -0800)
net/bluetooth/hci_sysfs.c: In function ‘del_conn’:
net/bluetooth/hci_sysfs.c:339: warning: suggest parentheses around assignment used as truth value

Signed-off-by: David S. Miller <davem@davemloft.net>
net/bluetooth/hci_sysfs.c

index e13cf5ef144cd59a8a8f7eee15ae24d7826020ba..f5aff6d0988a401c9eaa9ff8d6ec6d7b930f7b11 100644 (file)
@@ -333,10 +333,14 @@ static int __match_tty(struct device *dev, void *data)
 
 static void del_conn(struct work_struct *work)
 {
-       struct device *dev;
        struct hci_conn *conn = container_of(work, struct hci_conn, work);
 
-       while (dev = device_find_child(&conn->dev, NULL, __match_tty)) {
+       while (1) {
+               struct device *dev;
+
+               dev = device_find_child(&conn->dev, NULL, __match_tty);
+               if (!dev)
+                       break;
                device_move(dev, NULL);
                put_device(dev);
        }