Embedded TCP/IP stack  4.7.0
Error Codes API

Detailed Description

When a socket call indicates a failure, it is possible to call the fnet_error_get() function to determine the error value.
Another way to determine the error value for a socket is to examine its SO_ERROR option.
Possible values for socket errors are defined by the fnet_error_t.

Enumerations

enum  fnet_error_t {
  FNET_ERR_OK,
  FNET_ERR_NO_DESC,
  FNET_ERR_NOMEM,
  FNET_ERR_AGAIN,
  FNET_ERR_BOUNDREQ,
  FNET_ERR_INVAL,
  FNET_ERR_DESTADDRREQ,
  FNET_ERR_MSGSIZE,
  FNET_ERR_NOPROTOOPT,
  FNET_ERR_PROTONOSUPPORT,
  FNET_ERR_OPNOTSUPP,
  FNET_ERR_AFNOSUPPORT,
  FNET_ERR_ADDRINUSE,
  FNET_ERR_ADDRNOTAVAIL,
  FNET_ERR_NETUNREACH,
  FNET_ERR_CONNABORTED,
  FNET_ERR_CONNRESET,
  FNET_ERR_ISCONN,
  FNET_ERR_NOTCONN,
  FNET_ERR_SHUTDOWN,
  FNET_ERR_INPROGRESS,
  FNET_ERR_TIMEDOUT,
  FNET_ERR_HOSTUNREACH,
  FNET_ERR_SYSNOTREADY,
  FNET_ERR_CONNCLOSED,
  FNET_ERR_IPDISABLED,
  FNET_ERR_BAD_DESC
}
 Possible socket error codes, returned by the fnet_error_get(), or used by the SO_ERROR option. More...
 

Functions

fnet_error_t fnet_error_get (void)
 Returns the last error that occurred. More...
 
void fnet_error_set (fnet_error_t error)
 Sets the error code. More...
 

© 2005-2020 by Andrej Butok. http://fnet.sourceforge.net