How to use a non-blocking TCP socket. [2022/04/06] Add title image [2022/03/08] Started. 소나무 기운 , 전자제품 개발/생산 How to use a non-blocking TCP socket. int flag = fcntl(client_sock, F_GETFL, 0); fcntl(client_sock, F_SETFL, flag | O_NONBLOCK); Blocking mode example #include #include #include #include #include #include #include #define BUF_SIZE 1024 void other_routine(); int main(int argc, char **argv) { if (argc != 2) { printf("Usage : %s.. 2022. 3. 8. 이전 1 다음