mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-02-22 06:41:17 +00:00
don't cache transport fd
This commit is contained in:
parent
c095e79e4d
commit
1f6803779e
@ -111,7 +111,7 @@ int main (int argc, const char * argv[]) {
|
||||
|
||||
bt_control_t * control = NULL;
|
||||
|
||||
#if 0
|
||||
#if 1
|
||||
//
|
||||
if (argc <= 1){
|
||||
printf("HCI Daemon tester. Specify device name for Ericsson ROK 101 007\n");
|
||||
@ -151,10 +151,7 @@ int main (int argc, const char * argv[]) {
|
||||
|
||||
// init L2CAP
|
||||
l2cap_init();
|
||||
|
||||
// get fd for select call
|
||||
int transport_fd = transport->get_fd();
|
||||
|
||||
|
||||
//
|
||||
fd_set descriptors;
|
||||
FD_ZERO(&descriptors);
|
||||
@ -162,6 +159,8 @@ int main (int argc, const char * argv[]) {
|
||||
// handle HCI
|
||||
hci_run();
|
||||
|
||||
// get fd for select call
|
||||
int transport_fd = transport->get_fd();
|
||||
FD_SET(transport_fd, &descriptors);
|
||||
// int ready =
|
||||
select( transport_fd+1, &descriptors, NULL, NULL, NULL);
|
||||
|
Loading…
x
Reference in New Issue
Block a user