Commit 3f3498bc authored by Andrey Vagin's avatar Andrey Vagin Committed by Pavel Emelyanov

net: a file descriptor can be zero

Signed-off-by: 's avatarAndrey Vagin <avagin@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent f2a46c3d
......@@ -317,7 +317,7 @@ static int restore_ip_dump(int type, int pid, char *cmd)
int fd, ret;
ret = fd = open_image_ro(type, pid);
if (fd > 0) {
if (fd >= 0) {
ret = run_ip_tool(cmd, "restore", fd, -1);
close(fd);
}
......
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