durusmail: quixote-users: Forking question
Forking question
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-19
2004-05-20
Forking question
Jon Dugan
2004-05-19
On Wed, May 19, 2004 at 12:39:49PM -0400, Neil Schemenauer wrote:
> On Wed, May 19, 2004 at 11:19:27AM -0500, Jon Dugan wrote:
> >     def kill_process(self,cmd):
> >         os.kill(self.server_pid, 9)
> >         return os.waitpid(self.server_pid,0)
>
> That's a little brutal, don't you think?  You should probably start
> with SIGTERM (15) before resorting to SIGKILL (9).

  Heh.  I suppose so.  The code I ripped this out of is geared towards one
  thing and in that application the SIGKILL is fine.  In general it's probably
  better to be a bit more polite.

Jon
--
Jon Dugan             |  Senior Network Engineer, NCSA Network Research
jdugan@ncsa.uiuc.edu  |  269 CAB, 605 E Springfield, Champaign, IL 61820
217-244-7715          |  http://www.ncsa.uiuc.edu/~jdugan/


reply