MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / test_success

Function test_success

test/sockets/test_tcp_server.c:44–54  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

42}
43
44void test_success(void) {
45 printf("TCP SERVER PASS\n");
46 if (listen_fd >= 0) close(listen_fd);
47 if (client_fd >= 0) close(client_fd);
48 if (peer_fd >= 0) close(peer_fd);
49#ifdef __EMSCRIPTEN__
50 emscripten_cancel_main_loop();
51#else
52 exit(0);
53#endif
54}
55
56void start_client(void) {
57 if (client_fd >= 0) close(client_fd);

Callers 1

main_loopFunction · 0.70

Calls 3

printfFunction · 0.85
closeFunction · 0.50
exitFunction · 0.50

Tested by

no test coverage detected