En Tue, 29 Jul 2008 10:04:46 -0300, Gordon Maria <[EMAIL PROTECTED]> escribi�:

I'm running a GUI in python which is able to launch a separate python process that will run forever. In rare cases I will want to kill the launched process. Every time I do so, I end up with the process as defunct. Can anybody help me
clean it up in a nice way?

On request from GUI I do the following:
os.kill(process.pid,9)

FYI, it is all running on Linux.

You should call os.waitpid() after killing the child process, to let the OS free the resources allocated to it.

--
Gabriel Genellina

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to