3 ms·
I would think you could use dup (or dup2/ioctl) to de-register (assuming nothing grabbed that FD)?
by mnarayan01 10y ago
I would think you could use dup (or dup2/ioctl) to de-register (assuming nothing grabbed that FD)?
- DSMan195276 10y agoThat could possibly work, but only if you dup() the same original FD. If you just try dup()ing any random FD the internal file description pointer won't match, so epoll won't reconize it. But of course, if you have any threads then it's a big race condition.