2 ms·
Another point on your side is that close(); open(); is racy in threaded programs: to avoid the races you need to use dup2(), but that still has caveats related
by fanf2 5y ago
Another point on your side is that close(); open(); is racy in threaded programs: to avoid the races you need to use dup2(), but that still has caveats related to losing errors from close().