{
GError *error = NULL;
- if (!g_thread_supported()) {
- g_thread_init(NULL);
- }
-
dbus_threads_init_default();
if (session_conn != NULL)
dev_addr += 4;
g_strlcpy(address, dev_addr, sizeof(address));
- while ((pos = strchr(address, '_')) != NULL) {
+ while ((pos = strchr(address, '_')) != NULL)
*pos = ':';
- }
g_strlcpy(device_address, address, BT_ADDRESS_STRING_SIZE);
}
void _bt_convert_addr_string_to_type(unsigned char *addr,
const char *address)
{
- int i;
- char *ptr = NULL;
+ int i;
+ char *ptr = NULL;
ret_if(address == NULL);
ret_if(addr == NULL);
- for (i = 0; i < BT_ADDRESS_LENGTH_MAX; i++) {
- addr[i] = strtol(address, &ptr, 16);
- if (ptr[0] != '\0') {
- if (ptr[0] != ':')
- return;
+ for (i = 0; i < BT_ADDRESS_LENGTH_MAX; i++) {
+ addr[i] = strtol(address, &ptr, 16);
+ if (ptr[0] != '\0') {
+ if (ptr[0] != ':')
+ return;
- address = ptr + 1;
- }
- }
+ address = ptr + 1;
+ }
+ }
}
void _bt_convert_addr_string_to_secure_string(char *addr,
if (arg < 0)
return -errno;
- if (arg & O_NONBLOCK) {
+ if (arg & O_NONBLOCK)
BT_ERR("Already Non-blocking \n");
- }
arg |= O_NONBLOCK;
return NULL;
}
_bt_convert_device_path_to_address(object_path, device_address);
- if (g_strcmp0(address, device_address) == 0) {
+ if (g_strcmp0(address, device_address) == 0)
return g_strdup(object_path);
- }
+
}
BT_ERR("Unable to get object path");
{
int ret = ES_R_OK;
/* Send event system event in bt-core process because bt-service's permission is not system in now */
-\r#if 0
+
+#if 0
bundle *b = NULL;
b = bundle_create();