next up previous contents index
Next: 8.2.8 getpeername: get name Up: 8.2 oskit_socket: Socket Interface Previous: 8.2.6 listen: listen for

8.2.7 getsockname: get socket name

 

SYNOPSIS

#include <oskit/net/socket.h>

oskit_error_t oskit_socket_getsockname(oskit_socket_t *s, [out] struct oskit_sockaddr *asa, [in/out] oskit_size_t *anamelen);

DESCRIPTION

getsockname returns the current name for the specified socket.

PARAMETERS

s
The socket whose name is to be determined.

name
Contains the name of the socket upon return.

anamelen
Initially, the amount of space pointed to by name, on return it will contain the amount actually used, i.e., the actual size of the name.

RETURNS

Returns 0 on success, or an error code specified in <oskit/error.h>, on error.



University of Utah Flux Research Group