summaryrefslogtreecommitdiffstats
path: root/src/dbus-hci.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2009-02-27 18:21:25 +0200
committerJohan Hedberg <johan.hedberg@nokia.com>2009-02-27 18:21:25 +0200
commit363da064d395925f46be7793ece5800ec66a82ab (patch)
tree2235f89cbd772f69938c9280546eda1204ff4f59 /src/dbus-hci.c
parent041076b043f9d950ea9478cfea956b4cad040dfa (diff)
Don't call read scan enable if the adapter is powering down
When powering down we explicitly set the scan mode to 0 before calling the HCI_DEVDOWN ioctl. To avoid HCI command timeouts track this situation and don't call read scan enable in dbus-hci.c when the command complete for the write scan enable arrives.
Diffstat (limited to 'src/dbus-hci.c')
-rw-r--r--src/dbus-hci.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/dbus-hci.c b/src/dbus-hci.c
index 894b4492..65919083 100644
--- a/src/dbus-hci.c
+++ b/src/dbus-hci.c
@@ -1097,6 +1097,9 @@ void hcid_dbus_setscan_enable_complete(bdaddr_t *local)
return;
}
+ if (adapter_powering_down(adapter))
+ return;
+
dev_id = adapter_get_dev_id(adapter);
dd = hci_open_dev(dev_id);