tcpClose()

Closes a TCP/IP socket connection.

Synopsis

int tcpClose(int socket);

Parameters

Parameter Description
socket Number of socket

Return value

0 if OK, otherwise -1. Errors can be retrieved with getLastError().

Error

Missing or wrong arguments.

Description

Closes a TCP/IP socket connection.

Example

main()
{
  dyn_errClass err;
  int close, socket;
  socket=1;
  close=tcpClose(socket);
  err=getLastError();
  DebugN(close);
  DebugN(err);
}

Assignment

Communication functions

Availability

CTRL

See also