1. Fix build issue in OICCalloc
2. Added two API's (CALEClientIsConnected and CALEClientSendNegotiationMessage)
https://github.sec.samsung.net/RS7-IOTIVITY/IoTivity/pull/451
(cherry picked from
26a48f123f35e8d561f4cae381d182bea222a9e6)
Change-Id: Ic8735ab38d6277b6a40d6154344a5ccdd7d5ddf0
Signed-off-by: kush agrawal <kush.agrawal@samsung.com>
Signed-off-by: Abhishek Sansanwal <abhishek.s94@samsung.com>
if (result == BT_ERROR_NONE && NULL != man_data)
{
if (result == BT_ERROR_NONE && NULL != man_data)
{
- char *compare_man_data = OICMalloc((man_data_len*2)+1);
+ char *compare_man_data = OICCalloc(1, (man_data_len*2)+1);
int pos =0;
for(int i=0;i<man_data_len;i++){
pos += sprintf(compare_man_data+pos, "%.2x", man_data[i]);
}
int pos =0;
for(int i=0;i<man_data_len;i++){
pos += sprintf(compare_man_data+pos, "%.2x", man_data[i]);
}
- compare_man_data[(man_data_len*2)+1]='\0';
if (man_id == samsung_code && 0 == strncasecmp(compare_man_data, service_uuid, CUSTOM_UUID_LEN))
{
OIC_LOG_V(DEBUG, TAG, "Manufacture Data[%s] Found in %s",
if (man_id == samsung_code && 0 == strncasecmp(compare_man_data, service_uuid, CUSTOM_UUID_LEN))
{
OIC_LOG_V(DEBUG, TAG, "Manufacture Data[%s] Found in %s",
oc_mutex_unlock(g_LEServerListMutex);
return CA_DEFAULT_BLE_MTU_SIZE;
}
oc_mutex_unlock(g_LEServerListMutex);
return CA_DEFAULT_BLE_MTU_SIZE;
}
+
+bool CALEClientIsConnected(const char* address)
+{
+ (void)address;
+ //@Todo
+ return true;
+}
+
+CAResult_t CALEClientSendNegotiationMessage(const char* address)
+{
+ /* MCD : change the log as INFO_PRIVATE for security */
+ OIC_LOG_V(INFO_PRIVATE, TAG, "CALEClientSendNegotiationMessage(%s)", address);
+ //@Todo
+ //it will be implemented when tizen public 3.0 is released.
+ return CA_NOT_SUPPORTED;
+}