1
0
mirror of https://github.com/glfw/glfw.git synced 2025-04-13 04:12:02 +00:00

Linux: Set O_CLOEXEC on evdev fd

Closes 
This commit is contained in:
Victor Chernyakin 2023-12-15 00:53:32 -07:00 committed by Camilla Löwy
parent 9953f7ead1
commit edd38207a6

View File

@ -135,7 +135,7 @@ static GLFWbool openJoystickDevice(const char* path)
}
_GLFWjoystickLinux linjs = {0};
linjs.fd = open(path, O_RDONLY | O_NONBLOCK);
linjs.fd = open(path, O_RDONLY | O_NONBLOCK | O_CLOEXEC);
if (linjs.fd == -1)
return GLFW_FALSE;