result = adapter_set_le_static_random_address(is_enable);
if (result != OAL_STATUS_SUCCESS) {
- BT_ERR("adapter_set_connectable failed: %d", result);
+ BT_ERR("adapter_set_le_static_random_address failed: %d", result);
result = BLUETOOTH_ERROR_INTERNAL;
} else {
BT_INFO("SetLeStaticRandomAddress as %d", is_enable);
if (vconf_set_int(BT_FILE_VISIBLE_TIME, 0) != 0)
BT_ERR("Set vconf failed");
}
- } else {
- if (_bt_set_discoverable_mode(
- BLUETOOTH_DISCOVERABLE_MODE_CONNECTABLE,
- timeout) != BLUETOOTH_ERROR_NONE) {
- BT_ERR("Set connectable mode failed");
- }
}
#else
if (timeout == -1) {
if (vconf_set_int(BT_FILE_VISIBLE_TIME, 0) != 0)
BT_ERR("Set vconf failed");
}
- } else {
- if (_bt_set_discoverable_mode(
- BLUETOOTH_DISCOVERABLE_MODE_CONNECTABLE,
- timeout) != BLUETOOTH_ERROR_NONE) {
- BT_ERR("Set connectable mode failed");
- }
}
#endif
}