I am using system() to launch evince on Linux, it works fine until I load a document and try to close it. When I try to close the document system() never returns:
My code:
char systemString[MAXPATHLEN];
sprintf( systemString, "%s", "evince" );
int ret = system( systemString );
if ( ret == -1 )
{
perror( "system" );
exit(1);
}
Any idea why? If not, how do I debug this, when use it in the debugger it never returns in it either. The code is rather large and some signals are blocked, but I tried some I thought this used and same error.
Thanks
I found its because SIGTERM is being blocked but the program. This is a large legacy program.