MCPcopy Create free account
hub / github.com/bitcoinxt/bitcoinxt / CloseSocket

Function CloseSocket

src/netbase.cpp:1370–1381  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1368#endif
1369
1370bool CloseSocket(SOCKET& hSocket)
1371{
1372 if (hSocket == INVALID_SOCKET)
1373 return false;
1374#ifdef WIN32
1375 int ret = closesocket(hSocket);
1376#else
1377 int ret = close(hSocket);
1378#endif
1379 hSocket = INVALID_SOCKET;
1380 return ret != SOCKET_ERROR;
1381}
1382
1383bool SetSocketNonBlocking(SOCKET& hSocket, bool fNonBlocking)
1384{

Callers 9

Socks5Function · 0.85
ConnectSocketDirectlyFunction · 0.85
netbase.cppFile · 0.85
ConnectNodeFunction · 0.85
CloseSocketDisconnectMethod · 0.85
BOOST_FOREACHFunction · 0.85
BindListenPortFunction · 0.85
~CNetCleanupMethod · 0.85
~CNodeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected