do not return an error when user stops discovery 78/28878/2 accepted/tizen_3.0.2014.q3_common accepted/tizen_3.0.m14.3_ivi tizen_3.0.2014.q3_common tizen_3.0.m14.3_ivi accepted/tizen/3.0.2014.q3/common/20141022.093359 accepted/tizen/3.0.m14.3/ivi/20141022.104122 accepted/tizen/common/20141021.112443 accepted/tizen/ivi/20141022.015259 submit/tizen/20141021.025356 submit/tizen_3.0.2014.q3_common/20141021.112639 submit/tizen_3.0.m14.3_ivi/20141021.112858 submit/tizen_common/20141021.111902 submit/tizen_ivi/20141021.113442 tizen_3.0.2014.q3_common_release tizen_3.0.m14.3_ivi_release
authorCorentin Lecouvey <corentin.lecouvey@open.eurogiciel.org>
Thu, 16 Oct 2014 14:30:50 +0000 (16:30 +0200)
committerCorentin Lecouvey <corentin.lecouvey@open.eurogiciel.org>
Thu, 16 Oct 2014 14:34:02 +0000 (16:34 +0200)
Currently when user stops the discovery, it always returns an error.
When the discovery is stopped by the timeout callback, there is no error.
This workaround consists of never returns any error.

Change-Id: I9c5fa539f56997ec4210666e13cced600b58575f
Signed-off-by: Corentin Lecouvey <corentin.lecouvey@open.eurogiciel.org>
src/bluetooth-common.c

index 67a6cc1..b17f8c2 100644 (file)
@@ -523,7 +523,7 @@ static void __bt_event_proxy(int event, bluetooth_event_param_t *param, void *us
        case BLUETOOTH_EVENT_DISCOVERY_FINISHED:
                BT_INFO("bt_adapter_device_discovery_state_changed_cb() will be called with BT_ADAPTER_DEVICE_DISCOVERY_FINISHED");
                ((bt_adapter_device_discovery_state_changed_cb)bt_event_slot_container[event_index].callback)
-                   (_bt_get_error_code(param->result), BT_ADAPTER_DEVICE_DISCOVERY_FINISHED, NULL, bt_event_slot_container[event_index].user_data);
+                   (BT_ERROR_NONE, BT_ADAPTER_DEVICE_DISCOVERY_FINISHED, NULL, bt_event_slot_container[event_index].user_data);
                break;
        case BLUETOOTH_EVENT_REMOTE_DEVICE_NAME_UPDATED:
                BT_INFO("bt_adapter_device_discovery_state_changed_cb() will be called with BT_ADAPTER_DEVICE_DISCOVERY_FOUND");