提交 6bf0e469 编写于 作者: A Andrei Emeltchenko 提交者: Johan Hedberg

Bluetooth: Fix coding style issues in mgmt code

In this case we need to use braces in both branches.
Signed-off-by: NAndrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
上级 70c1f20b
...@@ -952,9 +952,9 @@ static int set_connectable(struct sock *sk, u16 index, void *data, u16 len) ...@@ -952,9 +952,9 @@ static int set_connectable(struct sock *sk, u16 index, void *data, u16 len)
if (!!cp->val != test_bit(HCI_CONNECTABLE, &hdev->dev_flags)) if (!!cp->val != test_bit(HCI_CONNECTABLE, &hdev->dev_flags))
changed = true; changed = true;
if (cp->val) if (cp->val) {
set_bit(HCI_CONNECTABLE, &hdev->dev_flags); set_bit(HCI_CONNECTABLE, &hdev->dev_flags);
else { } else {
clear_bit(HCI_CONNECTABLE, &hdev->dev_flags); clear_bit(HCI_CONNECTABLE, &hdev->dev_flags);
clear_bit(HCI_DISCOVERABLE, &hdev->dev_flags); clear_bit(HCI_DISCOVERABLE, &hdev->dev_flags);
} }
...@@ -987,9 +987,9 @@ static int set_connectable(struct sock *sk, u16 index, void *data, u16 len) ...@@ -987,9 +987,9 @@ static int set_connectable(struct sock *sk, u16 index, void *data, u16 len)
goto failed; goto failed;
} }
if (cp->val) if (cp->val) {
scan = SCAN_PAGE; scan = SCAN_PAGE;
else { } else {
scan = 0; scan = 0;
if (test_bit(HCI_ISCAN, &hdev->flags) && if (test_bit(HCI_ISCAN, &hdev->flags) &&
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册