MCPcopy Create free account
hub / github.com/acl-dev/acl / run

Function run

lib_acl/samples/udp/server/main.cpp:99–114  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97}
98
99static void run(const char *local_addr, int inter, int mio_on, int need_echo)
100{
101 SOCK_UDP *sock = udp_server_open(local_addr);
102
103 if (sock == NULL) {
104 printf("open_sock error!\r\n");
105 return;
106 }
107
108 if (mio_on)
109 mio(sock, inter, need_echo);
110 else
111 sio(sock, inter, need_echo);
112
113 udp_close(sock);
114}
115
116typedef struct {
117 char local[64];

Callers 2

thread_runFunction · 0.70
mainFunction · 0.70

Calls 4

udp_server_openFunction · 0.85
udp_closeFunction · 0.85
mioFunction · 0.70
sioFunction · 0.70

Tested by

no test coverage detected