coverity: #1437936

Unchecked return value Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent 99c42eaa
...@@ -908,13 +908,13 @@ static int attach_child_main(struct attach_clone_payload *payload) ...@@ -908,13 +908,13 @@ static int attach_child_main(struct attach_clone_payload *payload)
* may want to make sure the fds are closed, for example. * may want to make sure the fds are closed, for example.
*/ */
if (options->stdin_fd >= 0 && options->stdin_fd != STDIN_FILENO) if (options->stdin_fd >= 0 && options->stdin_fd != STDIN_FILENO)
dup2(options->stdin_fd, STDIN_FILENO); (void)dup2(options->stdin_fd, STDIN_FILENO);
if (options->stdout_fd >= 0 && options->stdout_fd != STDOUT_FILENO) if (options->stdout_fd >= 0 && options->stdout_fd != STDOUT_FILENO)
dup2(options->stdout_fd, STDOUT_FILENO); (void)dup2(options->stdout_fd, STDOUT_FILENO);
if (options->stderr_fd >= 0 && options->stderr_fd != STDERR_FILENO) if (options->stderr_fd >= 0 && options->stderr_fd != STDERR_FILENO)
dup2(options->stderr_fd, STDERR_FILENO); (void)dup2(options->stderr_fd, STDERR_FILENO);
/* close the old fds */ /* close the old fds */
if (options->stdin_fd > STDERR_FILENO) if (options->stdin_fd > STDERR_FILENO)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment