diff --git a/src/odoors/ODSpawn.c b/src/odoors/ODSpawn.c index ce2c4028eaf58e66c5ae3e8bc9d80d5b8d2e682b..8ac24e1baa952db76f382e1552b539b7141be52c 100644 --- a/src/odoors/ODSpawn.c +++ b/src/odoors/ODSpawn.c @@ -225,13 +225,22 @@ ODAPIDEF BOOL ODCALL od_spawn(char *pszCommandLine) #ifdef ODPLAT_NIX sigset_t block; + struct itimerval itv; + struct sigaction act; + int retval; /* Suspend kernel */ sigemptyset(&block); sigaddset(&block,SIGALRM); sigprocmask(SIG_BLOCK,&block,NULL); - return(system(pszCommandLine)==-1); + retval=system(pszCommandLine); + + /* Restore kernel */ + sigemptyset(&block); + sigaddset(&block,SIGALRM); sigprocmask(SIG_UNBLOCK,&block,NULL); + + return(retval==-1); #endif }