On Tue, 10 Jun 2003, Gerson Kurz wrote:
Zum Verständnis der Abhängigkeiten der Prozesse: Ich will *keinen* Kindprozess, ich will einen *eigenständigen* Prozess. [...] So sollte das ablaufen. Update kann nicht auf die Beendigung von main warten!
Da hilft dir der alte "double-fork" Trick. Hier die Implementation aus der ROX-Lib von Thomas Leonard: ---> schnipp <--- from os import fork, _exit, execvp, waitpid def spawn(argv): """Run a new process and forget about it""" child = fork() if child == 0: # We are the child child = fork() if child == 0: # Grandchild try: execvp(argv[0], argv) except: pass print "Warning: exec('%s') failed!" % argv[0] _exit(1) elif child == -1: print "Error: fork() failed!" _exit(1) elif child == -1: print "Error: fork() failed!" waitpid(child, 0) ---> schnapp <--- -- Christopher Arndt [t] +49 (0)177-3072812 linux consulting [w] www.chrisarndt.de & edv training [e] chris.arndt@web.de _______________________________________________ Python-de maillist - Python-de@python.net http://python.net/mailman/listinfo/python-de