JohnMudd <[EMAIL PROTECTED]> writes: > On Linux I get a "close failed: [Errno 10] No child processes" msg > for each fork. But only if I have a pipe open. I don't understand > the connection between the popen and the forks. Am I doing > something wrong?
Yes: don't use sys.exit, use os._exit. This is not specific to Python; in C you'd also need to use _exit(2) in preference to exit(3) to exit a forked process. With sys.exit(0) changed to os._exit(0), the program outputs: rate: 2962.1 fork/sec -- http://mail.python.org/mailman/listinfo/python-list