syscalls/bind: Use safe_macros to check the return value of the close() & bind().
PATCH 1/1 syscalls/bind: Use safe_macros to check the return value of the close() & bind().
For those:
testcases/kernel/syscalls/bind/bind03.c
testcases/kernel/syscalls/bind/bind06.c
Signed-off-by Xie Ziyao <[email protected]>
--- testcases/kernel/syscalls/bind/bind03.c | 4 ++-- testcases/kernel/syscalls/bind/bind06.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
testcases/kernel/syscalls/bind/bind03.c +2 -2
@@ -66,8 +66,8 @@ void run(void)static void cleanup (void ) { -close (sock1); -close (sock2); +SAFE_CLOSE (sock1); +SAFE_CLOSE (sock2); }static struct tst_test test = {
testcases/kernel/syscalls/bind/bind06.c +2 -2
@@ -60,8 +60,8 @@ static void cleanup(void)static void do_bind (void ) { -bind (fd, (struct sockaddr *)&addr1,sizeof (addr1)); -bind (fd, (struct sockaddr *)&addr2,sizeof (addr2)); +SAFE_BIND (fd, (struct sockaddr *)&addr1,sizeof (addr1)); +SAFE_BIND (fd, (struct sockaddr *)&addr2,sizeof (addr2)); }static void *thread_run (void *arg)
--
2.17.1
PATCH 1/1 syscalls/bind: Use safe_macros to check the return value of the close() & bind().
Hi Ziyao,
Thanks merged!
Kind regards,
Petr