未验证 提交 fd05ad76 编写于 作者: H HubretXie 提交者: GitHub

Update sal_socket.c

格式化代码
上级 2d82b621
...@@ -174,7 +174,7 @@ static void check_netdev_internet_up_work(struct rt_work *work, void *work_data) ...@@ -174,7 +174,7 @@ static void check_netdev_internet_up_work(struct rt_work *work, void *work_data)
goto __exit; goto __exit;
} }
skt_ops = pf->skt_ops; skt_ops = pf->skt_ops;
if((sockfd = skt_ops->socket(AF_INET, SOCK_DGRAM, 0)) < 0) if((sockfd = skt_ops->socket(AF_INET, SOCK_DGRAM, 0)) < 0)
{ {
result = -RT_ERROR; result = -RT_ERROR;
...@@ -394,7 +394,7 @@ static int socket_init(int family, int type, int protocol, struct sal_socket **r ...@@ -394,7 +394,7 @@ static int socket_init(int family, int type, int protocol, struct sal_socket **r
return -3; return -3;
} }
if (netdev_is_up(netdv_def)&&netdev_is_link_up(netdv_def)) if (netdev_is_up(netdv_def) && netdev_is_link_up(netdv_def))
{ {
/* check default network interface device protocol family */ /* check default network interface device protocol family */
pf = (struct sal_proto_family *) netdv_def->sal_user_data; pf = (struct sal_proto_family *) netdv_def->sal_user_data;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册