2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-30 22:05:36 +00:00

vdso: don't call close() for a negative value

CID 157801 (#1 of 1): Argument cannot be negative (NEGATIVE_RETURNS)
19. negative_returns: fd is passed to a parameter that cannot be negative.

Signed-off-by: Andrew Vagin <avagin@virtuozzo.com>
Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
This commit is contained in:
Andrew Vagin
2016-02-05 22:03:29 +03:00
committed by Pavel Emelyanov
parent a28c4a9979
commit 672f97ad4a

2
vdso.c
View File

@@ -212,7 +212,7 @@ int parasite_fixup_vdso(struct parasite_ctl *ctl, pid_t pid,
}
exit_code = 0;
err:
close(fd);
close_safe(&fd);
return exit_code;
}