Anope IRC Services  Version 1.8
Macros | Typedefs
sockets.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ano_sockread(fd, buf, len)   read(fd, buf, len)
 
#define ano_sockwrite(fd, buf, len)   write(fd, buf, len)
 
#define ano_sockclose(fd)   close(fd)
 
#define ano_sockgeterr()   errno
 
#define ano_sockseterr(err)   errno = err
 
#define ano_sockstrerror(err)   strerror(err)
 
#define ano_socksetnonb(fd)   fcntl(fd, F_SETFL, O_NONBLOCK)
 
#define ano_sockerrnonb(err)   (err == EINPROGRESS)
 
#define SOCKERR_EBADF   EBADF
 
#define SOCKERR_EINTR   EINTR
 
#define SOCKERR_EINVAL   EINVAL
 
#define SOCKERR_EINPROGRESS   EINPROGRESS
 

Typedefs

typedef int ano_socket_t
 

Macro Definition Documentation

#define ano_sockclose (   fd)    close(fd)

Definition at line 35 of file sockets.h.

Referenced by conn(), disconn(), smtp_connect(), smtp_disconnect(), smtp_read(), and smtp_send().

#define ano_sockerrnonb (   err)    (err == EINPROGRESS)

Definition at line 40 of file sockets.h.

#define ano_sockgeterr ( )    errno
#define ano_sockread (   fd,
  buf,
  len 
)    read(fd, buf, len)

Definition at line 33 of file sockets.h.

Referenced by buffered_read(), buffered_read_one(), and smtp_read().

#define ano_sockseterr (   err)    errno = err

Definition at line 37 of file sockets.h.

Referenced by buffered_read(), buffered_read_one(), buffered_write(), conn(), and flush_write_buffer().

#define ano_socksetnonb (   fd)    fcntl(fd, F_SETFL, O_NONBLOCK)

Definition at line 39 of file sockets.h.

#define ano_sockstrerror (   err)    strerror(err)

Definition at line 38 of file sockets.h.

Referenced by fatal_sockerror().

#define ano_sockwrite (   fd,
  buf,
  len 
)    write(fd, buf, len)

Definition at line 34 of file sockets.h.

Referenced by flush_write_buffer(), and smtp_send().

#define SOCKERR_EBADF   EBADF

Definition at line 41 of file sockets.h.

Referenced by buffered_read(), and buffered_read_one().

#define SOCKERR_EINPROGRESS   EINPROGRESS

Definition at line 44 of file sockets.h.

#define SOCKERR_EINTR   EINTR

Definition at line 42 of file sockets.h.

#define SOCKERR_EINVAL   EINVAL

Definition at line 43 of file sockets.h.

Referenced by conn().

Typedef Documentation

typedef int ano_socket_t

Definition at line 32 of file sockets.h.