From: Lukasz Bardeli Date: Wed, 1 Jul 2015 12:45:26 +0000 (+0200) Subject: [Bluetooth] Changes to remove warning X-Git-Tag: submit/tizen/20150702.103311^2~1^2~25^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=725832af1e4706b2b749961632fe05c1a658284b;p=platform%2Fcore%2Fapi%2Fwebapi-plugins.git [Bluetooth] Changes to remove warning [Verification] Code compiles without error Change-Id: I08e57c69463d442e075450b2ba341e4dd0cba402 Signed-off-by: Lukasz Bardeli --- diff --git a/src/bluetooth/bluetooth_adapter.cc b/src/bluetooth/bluetooth_adapter.cc index f94360bc..ac5f4010 100755 --- a/src/bluetooth/bluetooth_adapter.cc +++ b/src/bluetooth/bluetooth_adapter.cc @@ -341,8 +341,8 @@ BluetoothAdapter::BluetoothAdapter(BluetoothInstance& instance) : is_visible_(false), is_powered_(false), is_initialized_(false), - instance_(instance), - user_request_list_() + user_request_list_(), + instance_(instance) { LoggerD("Entered"); if (BT_ERROR_NONE == bt_initialize()) { diff --git a/src/bluetooth/bluetooth_gatt_service.cc b/src/bluetooth/bluetooth_gatt_service.cc index d9bc8183..d4c29e55 100755 --- a/src/bluetooth/bluetooth_gatt_service.cc +++ b/src/bluetooth/bluetooth_gatt_service.cc @@ -341,7 +341,7 @@ void BluetoothGATTService::ReadValue(const picojson::value& args, if (BT_ERROR_NONE != ret) { plarform_res = util::GetBluetoothError(ret, "Error while getting value"); } else { - for (size_t i = 0 ; i < length; i++) { + for (int i = 0 ; i < length; i++) { byte_array_obj.push_back(picojson::value(std::to_string(value[i]))); } } @@ -388,7 +388,7 @@ void BluetoothGATTService::WriteValue(const picojson::value& args, int value_size = value_array.size(); std::unique_ptr value_data(new char[value_size]); - for (size_t i = 0; i < value_size; ++i) { + for (int i = 0; i < value_size; ++i) { value_data[i] = static_cast(value_array[i].get()); } @@ -510,7 +510,7 @@ void BluetoothGATTService::OnCharacteristicValueChanged( picojson::value byte_array = picojson::value(picojson::array()); picojson::array& byte_array_obj = byte_array.get(); - for (size_t i = 0 ; i < length; ++i) { + for (int i = 0 ; i < length; ++i) { byte_array_obj.push_back(picojson::value(std::to_string(value[i]))); } diff --git a/src/bluetooth/bluetooth_instance.cc b/src/bluetooth/bluetooth_instance.cc index b3335760..f1b7a1db 100755 --- a/src/bluetooth/bluetooth_instance.cc +++ b/src/bluetooth/bluetooth_instance.cc @@ -28,8 +28,8 @@ using namespace common; BluetoothInstance::BluetoothInstance() : bluetooth_adapter_(*this), bluetooth_device_(bluetooth_adapter_), - bluetooth_health_profile_handler_(*this), bluetooth_health_application_(bluetooth_health_profile_handler_), + bluetooth_health_profile_handler_(*this), bluetooth_service_handler_(bluetooth_adapter_), bluetooth_socket_(bluetooth_adapter_), bluetooth_le_adapter_(*this), @@ -172,11 +172,6 @@ BluetoothInstance::~BluetoothInstance() namespace { const char* JSON_CALLBACK_ID = "callbackId"; const char* JSON_LISTENER_ID = "listenerId"; -const char* JSON_STATUS = "status"; -const char* JSON_RESULT = "result"; -const char* JSON_CALLBACK_SUCCCESS = "success"; -const char* JSON_CALLBACK_ERROR = "error"; -const char* JSON_DATA = "args"; } // namespace void BluetoothInstance::AsyncResponse(double callback_handle, const std::shared_ptr& response) {