Re: Authorization.h
Re: Authorization.h
- Subject: Re: Authorization.h
- From: Brian Hill <email@hidden>
- Date: Tue, 6 Nov 2001 07:34:31 -0600
Le mardi 6 novembre 2001, ` 07:26 AM, Charles Srstka a icrit :
The annoying thing about AuthorizationExecuteWithPrivileges is that
there is apparently no way to make your program wait for the tool to
exit before continuing! This can make things very difficult sometimes...
As long as you are only waiting for one child process at a time, you can
use the 'wait' function to wait until it exits.
#include <sys/wait.h>
wait(NULL);
//or
int status;
wait(&status);
//to get the exit status
Brian
email@hidden
http://personalpages.tds.net/~brian_hill
"Why? I came into this game for adventure - go anywhere, travel
light, get in, get out, wherever there's trouble, a man alone.
Now they've got the whole country sectioned off and you can't
move without a form. I'm the last of a breed."
-- Archibald "Harry" Tuttle, Rogue HVAC Repairman