* [LTP] [PATCH] runtest/syscalls: add sendmsg03
@ 2020-03-26 3:17 Yang Xu
2020-03-26 5:42 ` Li Wang
0 siblings, 1 reply; 2+ messages in thread
From: Yang Xu @ 2020-03-26 3:17 UTC (permalink / raw)
To: ltp
Also, fix a possible warning in cleanup when SAFE_UNSHARE(CLONE_NEWUSER)
failed on 3.10.0-1049.el7.x86_64. as below:
sendmsg03.c:43: CONF: unshare(268435456) unsupported: EINVAL (22)
safe_macros.c:67: WARN: sendmsg03.c:65: close(-1) failed: EBADF (9)
Signed-off-by: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
---
runtest/syscalls | 1 +
testcases/kernel/syscalls/sendmsg/sendmsg03.c | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/runtest/syscalls b/runtest/syscalls
index b797fb828..0ad66ca5e 100644
--- a/runtest/syscalls
+++ b/runtest/syscalls
@@ -1176,6 +1176,7 @@ sendfile09_64 sendfile09_64
sendmsg01 sendmsg01
sendmsg02 sendmsg02
+sendmsg03 sendmsg03
sendmmsg01 sendmmsg01
diff --git a/testcases/kernel/syscalls/sendmsg/sendmsg03.c b/testcases/kernel/syscalls/sendmsg/sendmsg03.c
index dcabfbb00..7dc491f75 100644
--- a/testcases/kernel/syscalls/sendmsg/sendmsg03.c
+++ b/testcases/kernel/syscalls/sendmsg/sendmsg03.c
@@ -62,7 +62,8 @@ static void setup(void)
static void cleanup(void)
{
- SAFE_CLOSE(sockfd);
+ if (sockfd > 0)
+ SAFE_CLOSE(sockfd);
tst_fzsync_pair_cleanup(&fzsync_pair);
}
--
2.23.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [LTP] [PATCH] runtest/syscalls: add sendmsg03
2020-03-26 3:17 [LTP] [PATCH] runtest/syscalls: add sendmsg03 Yang Xu
@ 2020-03-26 5:42 ` Li Wang
0 siblings, 0 replies; 2+ messages in thread
From: Li Wang @ 2020-03-26 5:42 UTC (permalink / raw)
To: ltp
On Thu, Mar 26, 2020 at 11:17:27AM +0800, Yang Xu wrote:
> Also, fix a possible warning in cleanup when SAFE_UNSHARE(CLONE_NEWUSER)
> failed on 3.10.0-1049.el7.x86_64. as below:
>
> sendmsg03.c:43: CONF: unshare(268435456) unsupported: EINVAL (22)
> safe_macros.c:67: WARN: sendmsg03.c:65: close(-1) failed: EBADF (9)
>
> Signed-off-by: Yang Xu <xuyang2018.jy@cn.fujitsu.com>
Pushed.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-03-26 5:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-26 3:17 [LTP] [PATCH] runtest/syscalls: add sendmsg03 Yang Xu
2020-03-26 5:42 ` Li Wang
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.