xHarbour Reference Documentation > Function Reference |
Closes a connection on a socket.
INetClose( <pSocket> ) --> nError
The function returns zero on success, or -1 on failure.
INetClose() closes a socket and notifies both ends of the connection. If threads are executing a blocking sockets function with <pSocket>, they will terminate their wait state and a socket error is set ("socket closed"). This causes all threads waiting on a blocking sockets function to resume so they can report a sockets error.
If the return value is not zero, use function INetErrorCode() to obtain information about failure.
See also: | INetAccept(), INetConnect(), INetDGram(), INetErrorCode() |
Category: | Internet functions , Sockets functions , xHarbour extensions |
Source: | vm\inet.c |
LIB: | xhb.lib |
DLL: | xhbdll.dll |
http://www.xHarbour.com