Re: help please!



Hi
I got those kinds of problem with a code like:
if (!fork())
{
 execlp(....);
 exit(1);
}
Because if the xec fails, exit is called, and there are some atexit() stuff
that send things to the X server, and this cause problems with the other
process.
The only soultion I've found is to replace the exit(1); by 
kill(getpid(), SIGKILL);

Maybe there is some a better to do that...

-- 
 ** Gael Le Mignot, Ing2 EPITA, Coder of The Kilobug Team **
Home Mail : kilobug freesurf fr              Work Mail : le-mig_g epita fr
GSM       : 06.71.47.18.22 (in France)   ICQ UIN   : 7299959

"Software is like sex: it's better when it's free.", Linus Torvalds





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]