return;
}
- connections = g_list_append(connections, rfsock_acc);
-
DBG("rfsock: fd %d real_sock %d chan %u sock %d",
rfsock->fd, rfsock->real_sock, rfsock->channel,
sock_acc);
return;
}
+ connections = g_list_append(connections, rfsock_acc);
+
/* Handle events from Android */
cond = G_IO_IN | G_IO_HUP | G_IO_ERR | G_IO_NVAL;
io_stack = g_io_channel_unix_new(rfsock_acc->fd);
}
rfsock->real_sock = g_io_channel_unix_get_fd(io);
- servers = g_list_append(servers, rfsock);
/* TODO: Add server watch */
g_io_channel_set_close_on_unref(io, TRUE);
rfsock->service_handle = sdp_service_register(profile, cmd->name);
+ servers = g_list_append(servers, rfsock);
+
return hal_fd;
}
return;
fail:
+ connections = g_list_remove(connections, rfsock);
cleanup_rfsock(rfsock);
}
return;
fail:
+ connections = g_list_remove(connections, rfsock);
cleanup_rfsock(rfsock);
}