I don't have the child's pid because the parent exits and I don't
really think this stays in the memory... My daemon fork and let
the child kill his parent (violence...) and thats it, later I want the same
parent to kill its child, how can you know the child's pid after he killed
you ?

It is something like:

import os
childpid = os.fork
if (childpid == 0):
           child_stuff()
else:
           os.exit()


----- Original Message -----
From: "Muli Ben-Yehuda" <[EMAIL PROTECTED]>
To: "Eliran" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, August 13, 2002 8:15 PM
Subject: Re: Run daemon + Stop daemon in python

So, what's the problem again? You have the child's pid, don't you?
Not to mention that if you use 'fetchmail -q', you don't need it
anyway!

You might want to look into os.system() to spawn a process in the
background, if you don't want to handle wait() yourself.



=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]

Reply via email to