[CRIU] [PATCH 1/3] zdtm: fix typo in socket-tcp-.*
Andrei Vagin
avagin at openvz.org
Fri Jan 20 12:21:25 PST 2017
From: Andrei Vagin <avagin at virtuozzo.com>
CID 174774 (#1 of 1): Logically dead code (DEADCODE)
dead_error_line: Execution cannot reach this statement: return 1;.
Signed-off-by: Andrei Vagin <avagin at virtuozzo.com>
---
test/zdtm/static/socket-tcp-close-wait.c | 2 +-
test/zdtm/static/socket-tcp-closing.c | 2 +-
test/zdtm/static/socket-tcp-fin-wait1.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/test/zdtm/static/socket-tcp-close-wait.c b/test/zdtm/static/socket-tcp-close-wait.c
index 6a7fdf8..be000a4 100644
--- a/test/zdtm/static/socket-tcp-close-wait.c
+++ b/test/zdtm/static/socket-tcp-close-wait.c
@@ -131,7 +131,7 @@ int main(int argc, char **argv)
return 1;
ctl_fd = tcp_init_client(ZDTM_FAMILY, "127.0.0.1", port);
- if (fd < 0)
+ if (ctl_fd < 0)
return 1;
/* == The preparation stage == */
diff --git a/test/zdtm/static/socket-tcp-closing.c b/test/zdtm/static/socket-tcp-closing.c
index 8574931..14c9227 100644
--- a/test/zdtm/static/socket-tcp-closing.c
+++ b/test/zdtm/static/socket-tcp-closing.c
@@ -125,7 +125,7 @@ int main(int argc, char **argv)
return 1;
ctl_fd = tcp_init_client(ZDTM_FAMILY, "127.0.0.1", port);
- if (fd < 0)
+ if (ctl_fd < 0)
return 1;
size = fill_sock_buf(fd);
diff --git a/test/zdtm/static/socket-tcp-fin-wait1.c b/test/zdtm/static/socket-tcp-fin-wait1.c
index 1d66f4e..f6d45c0 100644
--- a/test/zdtm/static/socket-tcp-fin-wait1.c
+++ b/test/zdtm/static/socket-tcp-fin-wait1.c
@@ -128,7 +128,7 @@ int main(int argc, char **argv)
write(fd, TEST_MSG, 2);
ctl_fd = tcp_init_client(ZDTM_FAMILY, "127.0.0.1", port);
- if (fd < 0)
+ if (ctl_fd < 0)
return 1;
if (read(ctl_fd, &c, 1) != 0) {
--
2.7.4
More information about the CRIU
mailing list