Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 1

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 1

Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 8

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 8

PtSpawnWait()

Spawn a process and wait for its termination

Synopsis:

int PtSpawnWait( const char *cmd,
                 const char **argv,
                 const char **env,
                 const PtSpawnOptions_t *opt,
                 pid_t *pidp );

Library:

ph

Description:

This function spawns a new process and waits for its termination. While the child process is running, Photon events are processed.

If pidp isn't NULL, the process ID of the spawned command is stored in *pidp. This can be used if callback functions need to communicate with the running child process.

The meaning of all the other arguments is the same as for the PtSpawn() function.

Returns:

The termination status of the child (see waitpid()), or -1 if the child process couldn't be started.

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

PtSpawn(), PtSpawnSetCallback(), PtSpawnDeleteCallback()


Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 102

Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptspawnwait.html on line 102