More fun with file descriptors
Posted Jun 14, 2007 14:41 UTC (Thu) by
nix (subscriber, #2304)
In reply to:
More fun with file descriptors by davecb
Parent article:
More fun with file descriptors
That works fine in apps, but not in libraries. If a library wants to open some persistent fd, it currently has no guarantee that the app hasn't closed that fd on it, or dup2()ed another one over the top of it. I've seen problems with syslog() caused by exactly this in the past, and even problems with the three standard fds (buggy app closes them all rather than opening /dev/null three times and wackiness ensues.)
(
Log in to post comments)