net/sockopt: fix nxstyle warning
Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
parent
608436a75f
commit
03f462c5cd
@ -92,7 +92,8 @@
|
||||
****************************************************************************/
|
||||
|
||||
static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
FAR void *value, FAR socklen_t *value_len)
|
||||
FAR void *value,
|
||||
FAR socklen_t *value_len)
|
||||
{
|
||||
/* Verify that the socket option if valid (but might not be supported ) */
|
||||
|
||||
@ -121,7 +122,8 @@ static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
|
||||
default: /* Other options are passed to usrsock daemon. */
|
||||
{
|
||||
return usrsock_getsockopt(conn, SOL_SOCKET, option, value, value_len);
|
||||
return usrsock_getsockopt(conn, SOL_SOCKET,
|
||||
option, value, value_len);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -276,7 +278,9 @@ static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
}
|
||||
break;
|
||||
|
||||
/* The following are not yet implemented (return values other than {0,1) */
|
||||
/* The following are not yet implemented
|
||||
* (return values other than {0,1})
|
||||
*/
|
||||
|
||||
case SO_LINGER: /* Lingers on a close() if data is present */
|
||||
case SO_RCVBUF: /* Sets receive buffer size */
|
||||
@ -431,7 +435,8 @@ int psock_getsockopt(FAR struct socket *psock, int level, int option,
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int getsockopt(int sockfd, int level, int option, void *value, socklen_t *value_len)
|
||||
int getsockopt(int sockfd, int level, int option,
|
||||
void *value, socklen_t *value_len)
|
||||
{
|
||||
FAR struct socket *psock;
|
||||
int ret;
|
||||
|
@ -87,7 +87,8 @@
|
||||
****************************************************************************/
|
||||
|
||||
static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
FAR const void *value, socklen_t value_len)
|
||||
FAR const void *value,
|
||||
socklen_t value_len)
|
||||
{
|
||||
/* Verify that the socket option if valid (but might not be supported ) */
|
||||
|
||||
@ -259,7 +260,9 @@ static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
|
||||
net_lock();
|
||||
|
||||
/* Set or clear the linger option bit and linger time (in deciseconds) */
|
||||
/* Set or clear the linger option bit and linger time
|
||||
* (in deciseconds)
|
||||
*/
|
||||
|
||||
if (setting->l_onoff)
|
||||
{
|
||||
@ -315,8 +318,8 @@ static int psock_socketlevel_option(FAR struct socket *psock, int option,
|
||||
* See <sys/socket.h> a complete list of values for the socket level
|
||||
* 'option' argument.
|
||||
*
|
||||
* Protocol level options, such as SOL_TCP, are defined in protocol-specific
|
||||
* header files, for example include/netinet/tcp.h
|
||||
* Protocol level options, such as SOL_TCP, are defined in
|
||||
* protocol-specific header files, for example include/netinet/tcp.h
|
||||
*
|
||||
* Input Parameters:
|
||||
* psock Socket structure of socket to operate on
|
||||
@ -419,8 +422,8 @@ int psock_setsockopt(FAR struct socket *psock, int level, int option,
|
||||
* See <sys/socket.h> a complete list of values for the socket level
|
||||
* 'option' argument.
|
||||
*
|
||||
* Protocol level options, such as SOL_TCP, are defined in protocol-specific
|
||||
* header files, for example include/netinet/tcp.h
|
||||
* Protocol level options, such as SOL_TCP, are defined in
|
||||
* protocol-specific header files, for example include/netinet/tcp.h
|
||||
*
|
||||
* Input Parameters:
|
||||
* sockfd Socket descriptor of socket
|
||||
|
Loading…
Reference in New Issue
Block a user