[asterisk-users] [Linux/Python 2.4.2] Forking Python doesn't work

Vincent vincent.delporte at bigfoot.com
Thu Feb 14 08:00:42 CST 2008


On Wed, 13 Feb 2008 22:26:16 -0500, Russell Bryant
<russell at digium.com> wrote:
>The arguments to System() are a bit different.  Put it in just like you would 
>type at the command line.
>
>System(/tmp/netcid.py 2000 Joe)

That did it :-) Thanks guys.

BTW, for those interested, I didn't have to double-fork:

======
#!/usr/bin/python

import socket,sys,time,os

sys.stdout = open(os.devnull, 'w')
if os.fork():
	sys.exit(0)
else:
	#Here, send broadcast
======




More information about the asterisk-users mailing list