diff --git a/android/bluetooth.c b/android/bluetooth.c
index 34690b7..38ee9a9 100644
--- a/android/bluetooth.c
+++ b/android/bluetooth.c
}
}
+static void clear_auto_connect_list_complete(uint8_t status,
+ uint16_t length,
+ const void *param,
+ void *user_data)
+{
+ if (status != MGMT_STATUS_SUCCESS)
+ error("Failed to clear auto connect list: %s (0x%02x)",
+ mgmt_errstr(status), status);
+}
+
+static void clear_auto_connect_list(void)
+{
+ struct mgmt_cp_remove_device cp;
+
+ if (!kernel_conn_control)
+ return;
+
+ memset(&cp, 0, sizeof(cp));
+
+ if (mgmt_send(mgmt_if, MGMT_OP_REMOVE_DEVICE, adapter.index,
+ sizeof(cp), &cp,
+ clear_auto_connect_list_complete,
+ NULL, NULL) > 0)
+ return;
+
+ error("Could not clear auto connect list");
+}
+
static void read_info_complete(uint8_t status, uint16_t length,
const void *param, void *user_data)
{
register_mgmt_handlers();
clear_uuids();
+ clear_auto_connect_list();
set_io_capability();
set_device_id();