APM: Spawning processes
michalk at awpi.com
Wed Jul 21 09:35:01 CDT 2004
Thanks. That was pretty close. It turned out to need something like this:
347 exec("./$0 2>&1 &");
348 exit 0;
From: Ian Ragsdale [mailto:ian at SKYLIST.net]
Sent: Tuesday, July 20, 2004 3:42 PM
To: Brian Michalk
Cc: austin at mail.pm.org
Subject: Re: APM: Spawning processes
I think just calling "exec($0, @ARGV);" will do what you want.
On Jul 20, 2004, at 3:36 PM, Brian Michalk wrote:
> I have come across a scenario where the shell environment changes.
> this happens, I could clean up all of my network sockets, and restore
> everything, but it would be much simpler to just restart.
> What would the preferred method be? The respawned process needs to
> because we will be killing the parent.
> Something like:
> System "run_my_program.pl &";
> Exit 0;
> Maybe a fork()?????
> Austin mailing list
> Austin at mail.pm.org
More information about the Austin