MCPcopy Create free account
hub / github.com/defold/defold / socket_destroy

Function socket_destroy

engine/script/src/luasocket/wsocket.c:93–99  ·  view source on GitHub ↗

-------------------------------------------------------------------------*\ * Close and inutilize socket \*-------------------------------------------------------------------------*/

Source from the content-addressed store, hash-verified

91* Close and inutilize socket
92\*-------------------------------------------------------------------------*/
93void socket_destroy(p_socket ps) {
94 if (*ps != SOCKET_INVALID) {
95 socket_setblocking(ps); /* close can take a long time on WIN32 */
96 closesocket(*ps);
97 *ps = SOCKET_INVALID;
98 }
99}
100
101/*-------------------------------------------------------------------------*\
102*

Callers 10

meth_closeFunction · 0.70
tryconnect6Function · 0.70
global_connectFunction · 0.70
unix_trybindFunction · 0.70
unix_tryconnectFunction · 0.70
meth_closeFunction · 0.70
inet_tryconnectFunction · 0.70
inet_trybindFunction · 0.70
meth_closeFunction · 0.70
meth_closeFunction · 0.70

Calls 1

socket_setblockingFunction · 0.70

Tested by

no test coverage detected