vfio: Add O_CLOEXEC flag to vfio device fd
authorAlex Williamson <alex.williamson@redhat.com>
Thu, 22 Aug 2013 16:33:41 +0000 (10:33 -0600)
committerAlex Williamson <alex.williamson@redhat.com>
Thu, 22 Aug 2013 16:33:41 +0000 (10:33 -0600)
Add the default O_CLOEXEC flag for device file descriptors.  This is
generally considered a safer option as it allows the user a race free
option to decide whether file descriptors are inherited across exec,
with the default avoiding file descriptor leaks.

Reported-by: Yann Droneaud <ydroneaud@opteya.com>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>

No differences found