Up to [cvs.NetBSD.org] / src / sys / kern
Request diff between arbitrary revisions
Default branch: MAIN
Current tag: nick-hppapmap-base
Revision 1.188 / (download) - annotate - [select for diffs], Sat Apr 4 10:12:51 2009 UTC (14 years, 11 months ago) by ad
Branch: MAIN
CVS Tags: nick-hppapmap-base4,
nick-hppapmap-base3,
nick-hppapmap-base
Changes since 1.187: +18 -4
lines
Diff to previous 1.187 (colored)
Add fileops::fo_drain(), to be called from fd_close() when there is more than one active reference to a file descriptor. It should dislodge threads sleeping while holding a reference to the descriptor. Implemented only for sockets but should be extended to pipes, fifos, etc. Fixes the case of a multithreaded process doing something like the following, which would have hung until the process got a signal. thr0 accept(fd, ...) thr1 close(fd)