A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2000-August/008561.html below:

[Python-Dev] Who can make test_fork1 fail?

[Python-Dev] Who can make test_fork1 fail? [Python-Dev] Who can make test_fork1 fail?Charles G Waldman cgw@fnal.gov
Sat, 19 Aug 2000 00:26:33 -0500 (CDT)
Tim Peters writes:

 > Since nobody has made real progress on figuring out why test_fork1 
 > fails on some systems,  would somebody who is able to make it fail
 > please just try this patch & see what happens?

Or try this program (based on Neil's example), which will fail almost
immediately unless you apply my patch:


import thread
import os, sys
import time

def doit(name):
    while 1:
        if os.fork()==0:
            print name, 'forked', os.getpid()
            os._exit(0)
        r = os.wait()

for x in range(50):
    name = 't%s'%x
    print 'starting', name
    thread.start_new_thread(doit, (name,))

time.sleep(300)




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4