Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Kernel Liteos A
提交
9bb4be5e
K
Kernel Liteos A
项目概览
OpenHarmony
/
Kernel Liteos A
1 年多 前同步成功
通知
464
Star
414
Fork
55
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
4
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel Liteos A
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
4
Issue
4
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
9bb4be5e
编写于
6月 19, 2022
作者:
N
Neil Chen
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix typos for net
Signed-off-by:
N
Neil Chen
<
jingsi.chen@petalmail.com
>
上级
4acf1e9f
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
11 addition
and
11 deletion
+11
-11
net/lwip-2.1/enhancement/src/api_shell.c
net/lwip-2.1/enhancement/src/api_shell.c
+10
-10
net/lwip-2.1/enhancement/src/dhcps.c
net/lwip-2.1/enhancement/src/dhcps.c
+1
-1
未找到文件。
net/lwip-2.1/enhancement/src/api_shell.c
浏览文件 @
9bb4be5e
...
...
@@ -243,7 +243,7 @@ struct ifconfig_option {
unsigned
char
ethaddr
[
6
];
u16_t
mtu
;
/* when using telnet, print to the telnet socket will result in system */
/* deadlock. So we ca
he the prinf data to a buf, and when the tcpip
*/
/* deadlock. So we ca
che the print data to a buf, and when the tcpip
*/
/* callback returns, then print the data out to the telnet socket */
sys_sem_t
cb_completed
;
char
cb_print_buf
[
PRINT_BUF_LEN
];
...
...
@@ -1158,9 +1158,9 @@ struct arp_option {
unsigned
int
ipaddr
;
/* hw addr */
unsigned
char
ethaddr
[
6
];
/* when using telnet, print
f
to the telnet socket will result in system */
/* deadlock.so don't do it.
cahe the data to prinf to a buf, and when
*/
/* callback returns, then print
f
the data out to the telnet socket */
/* when using telnet, print to the telnet socket will result in system */
/* deadlock.so don't do it.
cache the data to print to a buf, and when
*/
/* callback returns, then print the data out to the telnet socket */
sys_sem_t
cb_completed
;
char
cb_print_buf
[
PRINT_BUF_LEN
];
int
print_buf_len
;
...
...
@@ -1326,7 +1326,7 @@ out:
}
else
if
(
ret
==
ERR_RTE
)
{
(
void
)
snprintf_s
(
arp_cmd
->
cb_print_buf
,
PRINT_BUF_LEN
,
(
PRINT_BUF_LEN
-
1
),
"Network is unreachable
\n
"
);
}
else
{
(
void
)
snprintf_s
(
arp_cmd
->
cb_print_buf
,
PRINT_BUF_LEN
,
(
PRINT_BUF_LEN
-
1
),
"Succe
ss
ed
\n
"
);
(
void
)
snprintf_s
(
arp_cmd
->
cb_print_buf
,
PRINT_BUF_LEN
,
(
PRINT_BUF_LEN
-
1
),
"Succe
ed
ed
\n
"
);
}
}
#endif
...
...
@@ -2234,13 +2234,13 @@ u32_t osShellPing6(int argc, const char **argv)
}
if
((
u32_t
)
ret
<
sizeof
(
struct
icmp6_echo_hdr
*
))
{
/* Drop the packet if its too short [Doesn
o
t contain even the header !!] */
/* Drop the packet if its too short [Doesn
'
t contain even the header !!] */
PRINTK
(
"ping6 : received ICMP echo response too short
\n
"
);
goto
REDUCE_SELECT_TIME
;
}
/* Acceping the ICMPv6 payload. */
/* Here, pbuf_resp->payload wont contain IPv6 Header since its an AF_INET6 RAW Socket */
/* Here, pbuf_resp->payload won
'
t contain IPv6 Header since its an AF_INET6 RAW Socket */
iecho_resp
=
(
struct
icmp6_echo_hdr
*
)
pbuf_resp
->
payload
;
if
(
iecho_resp
->
id
==
icmpv6_id
)
{
...
...
@@ -2283,7 +2283,7 @@ u32_t osShellPing6(int argc, const char **argv)
/* Checking if its a delayed packet */
if
((
iecho_resp
->
seqno
!=
icmpv6_seq
)
&&
(
nsent
<
ping6_params
.
pingcount
))
{
/* Incase of delayed packet wait on socket for other response before sending a new PING */
/* In
case of delayed packet wait on socket for other response before sending a new PING */
/* We have to reduce the timeout value now when selecting on socket */
goto
REDUCE_SELECT_TIME
;
}
...
...
@@ -2313,7 +2313,7 @@ REDUCE_SELECT_TIME:
nsent
,
nrecieve
,
(
float
)(((
float
)(
nsent
-
nrecieve
))
*
((
float
)(
100
))
/
((
float
)(
nsent
))),
((
last
.
tv_sec
-
first
.
tv_sec
)
*
1000
+
(
last
.
tv_nsec
-
first
.
tv_nsec
)
/
1000000
));
if
(
nrecieve
)
{
/* Display rtt stats only if atleast one packet is received */
/* Display rtt stats only if at
least one packet is received */
PRINTK
(
"rtt min/avg/max = %u/%.2f/%u ms
\n
"
,
ping6_stats
.
min_rtt
,
ping6_stats
.
avg_rtt
,
ping6_stats
.
max_rtt
);
}
...
...
@@ -2778,7 +2778,7 @@ int netstat_get_udp_sendQLen6(struct udp_pcb *udppcb, struct pbuf *udpbuf)
goto
FUNC_OUT
;
}
/* check if there is enough space for atleast udp header available */
/* check if there is enough space for at
least udp header available */
if
(
udpbuf
->
tot_len
<
UDP_HLEN
)
{
goto
FUNC_OUT
;
}
...
...
net/lwip-2.1/enhancement/src/dhcps.c
浏览文件 @
9bb4be5e
...
...
@@ -601,7 +601,7 @@ LWIP_STATIC void handle_request(struct netif *netif, struct dhcps *dhcps, struct
dhcp_common_option_byte
(
srvr_msg
,
DHCP_NAK
,
&
options_len
);
/* Just set this here, so that the NAK message is brcasted.
The correct flags has already been added in the respose message during base message creation */
The correct flags has already been added in the respo
n
se message during base message creation */
client_msg
->
flags
|=
htons
(
DHCP_BROADCAST_FLAG
);
client_msg
->
ciaddr
.
addr
=
0
;
/* This is done so that NAK Gets brcasted */
#ifdef LWIP_DEV_DEBUG
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录