nn::socket::GetSockOpt Function

Syntax

s32 GetSockOpt(
     s32 s,
     s32 level,
     int optname,
     void * optval,
     int * optlen
);

Arguments

Name Description
in s Specifies the socket descriptor. Specify a socket descriptor created using the Socket or Accept function.
in level Specifies the target protocol layer (SocketLevel).
in optname Specifies the target options (SocketOptionType).
out optval Specifies the buffer in which to store the setting.
inout optlen Specifies the optval buffer length for optname.

Return Values



Value Description
0 Process was successful.
ENETRESET Socket library is not initialized.
EBADF Invalid socket descriptor.
EINVAL Invalid processing.

Description

Gets a socket's internal settings and internal state.

See Also

SetSockOpt

Revision History

2010/06/14
Initial version.

CONFIDENTIAL