diff options
author | Michel Dänzer <michel.daenzer@amd.com> | 2018-05-18 11:23:00 +0200 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2018-05-21 13:56:38 -0400 |
commit | ab53e2859facecc0486344679dc01ea31fb427e9 (patch) | |
tree | f697766a324e45ec04735606473f8e38f19dc895 | |
parent | 1e9d5533e3c08fc22099d6dd0f11fa642ab4f1b0 (diff) |
xfree86: Fix O_CLOEXEC usage in lnx_platform
It was passing O_CLOEXEC as permission bits instead of as a flag.
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
-rw-r--r-- | hw/xfree86/os-support/linux/lnx_platform.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/xfree86/os-support/linux/lnx_platform.c b/hw/xfree86/os-support/linux/lnx_platform.c index 11af52c46..70374ace8 100644 --- a/hw/xfree86/os-support/linux/lnx_platform.c +++ b/hw/xfree86/os-support/linux/lnx_platform.c @@ -43,7 +43,7 @@ get_drm_info(struct OdevAttributes *attribs, char *path, int delayed_index) } if (fd == -1) - fd = open(path, O_RDWR, O_CLOEXEC); + fd = open(path, O_RDWR | O_CLOEXEC, 0); if (fd == -1) return FALSE; |