1 #include <sys/time.h> // work around module map issue with iOS sdk, <rdar://problem/35159346>
2 #include <sys/select.h>
8 select_thread (void *in
)
10 pthread_setname_np ("select thread");
12 FD_SET (STDIN_FILENO
, &fdset
);
14 select (2, &fdset
, NULL
, NULL
, NULL
);
21 sleep(1); // break here
26 pthread_setname_np ("main thread");
27 pthread_t other_thread
;
28 pthread_create (&other_thread
, NULL
, select_thread
, NULL
);