sockaddr_in
sockaddr_in (port
,addr_string
)
pack_sockaddr_in (port, addr_string)
- Takes a port number and a four-byte addr_string (as returned by
inet_aton
) and returns the socket address structure including those arguments packed with the AF_INET argument. This structure is normally what you need for the arguments inbind
,connect
, andsend
, and is also returned bygetpeername
,getsockname
, andrecv
.