Akopia Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Re: [mv] Global Subs



******    message to minivend-users from Mike Heins <mikeh@minivend.com>     ******

Quoting Cameron B. Prince (cbp@internetexpertsllc.com):
> 
> I gave this a try and it does run the script, but it runs it identical to
> GlobalSubs in the Minivend.cfg
> 
> Minivend runs the program and waits for it to complete before mv_nextpage is
> loaded.
> 
> I need the process to spawn off individually and Minivend shouldn't wait on
> it before feeding the next page to the browser.
> 
> 
> Could anyone explain how this is done?
> 

You have to double-fork, for the wait() call will wait for any
associated children. In Perl, you do something like:

	my $pid;
	if(! defined $pid = fork()) {
		die "Can't fork!";
	}
	elsif (! $pid) {
		unless (fork()) {
			system "your_program";
		}
	}
	wait();

I don't recommend doing this often, though, on a busy system.

-- 
Internet Robotics, 131 Willow Lane, Floor 2, Oxford, OH  45056
phone +1.513.523.7621 fax 7501 <mikeh@minivend.com>

I have a cop friend who thinks he ought be able to give a new ticket;
"too dumb for conditions".
-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: