1 Star 0 Fork 11

shirely/lksctp-tools

forked from src-openEuler/lksctp-tools 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
bugfix-Fix-error-errno-typos.patch 1.39 KB
一键复制 编辑 原始数据 按行查看 历史
shirely16 提交于 2020-07-15 15:55 . update to lksctp-tools-1.0.18
From f0183c87b15a9b1ad06db88325d7e5eeddb89c7f Mon Sep 17 00:00:00 2001
From: Jianwen Ji <[email protected]>
Date: Tue, 18 Dec 2018 14:40:37 +0800
Subject: [PATCH 08/11] Fix error->errno typos
Signed-off-by: Jianwen Ji <[email protected]>
Signed-off-by: Marcelo Ricardo Leitner <[email protected]>
---
src/apps/sctp_status.c | 2 +-
src/apps/sctp_test.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/apps/sctp_status.c b/src/apps/sctp_status.c
index 46e9ca2..8563cbe 100644
--- a/src/apps/sctp_status.c
+++ b/src/apps/sctp_status.c
@@ -529,7 +529,7 @@ int receive_r(int sk)
DEBUG_PRINT(DEBUG_MIN, "\trecvmsg(sk=%d) ", sk);
error = recvmsg(sk, &inmessage, MSG_WAITALL);
- if (error < 0 && error != EAGAIN) {
+ if (error < 0 && errno != EAGAIN) {
fprintf(stderr, "\n\t\t*** recvmsg: %s ***\n\n",
strerror(errno));
fflush(stdout);
diff --git a/src/apps/sctp_test.c b/src/apps/sctp_test.c
index 4aa2d13..cd7654b 100644
--- a/src/apps/sctp_test.c
+++ b/src/apps/sctp_test.c
@@ -870,7 +870,7 @@ int receive_r(int sk, int once)
DEBUG_PRINT(DEBUG_MIN, "\trecvmsg(sk=%d) ", sk);
error = recvmsg(recvsk, &inmessage, MSG_WAITALL);
- if (error < 0 && error != EAGAIN) {
+ if (error < 0 && errno != EAGAIN) {
if (errno == ENOTCONN && socket_type == SOCK_STREAM &&
role == SERVER) {
printf("No association is present now!!\n");
--
1.8.3.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/shirely16/lksctp-tools.git
[email protected]:shirely16/lksctp-tools.git
shirely16
lksctp-tools
lksctp-tools
master

搜索帮助