The workaround i got is simply to do a exec of a little bash script and to fork in bash. system was causing issues with the output. The current version is along the line:
// build the cooked_cmdline
$cooked_cmdline = $cmdline.' >/dev/null 2>/dev/null & echo $!';
// execute the cooked cmdline
$pid_str = exec($cooked_cline, $retval);
// convert $pid_str into integer
$pid = (integer)$pid_str;
Rather ugly, i will likely post something better later.
Update: i made a plugin to handle this called sfWorkerPlugin.

0 comments:
Post a Comment