Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

> Isn’t this the whole point of using file descriptors?

Opening the same file multiple times will yield different fds, and the paths can be modified independently of the fd.

The goal here is to find if:

1. there are new input devices

2. which are joysticks (a category which, for SDL, includes gamepads, so basically "has the user plugged in a new gamepad they might want to use for the game")

How would keeping a bunch of fds around help?



Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: