Enlightenment CVS committal
Author : raster
Project : e17
Module : apps/entrance
Dir : e17/apps/entrance/src/daemon
Modified Files:
spawner.c
Log Message:
timeout was wrong... and we shoudl consider DIY cmd-line parsing... see comment
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/entrance/src/daemon/spawner.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -3 -r1.23 -r1.24
--- spawner.c 17 Aug 2004 03:40:31 -0000 1.23
+++ spawner.c 16 Jan 2005 04:55:39 -0000 1.24
@@ -121,11 +121,6 @@
pid_t xpid;
d->status = LAUNCHING;
- /* Initialize signal handler for SIGUSR1 */
- _entrance_x_sa.sa_handler = SIG_IGN;
- _entrance_x_sa.sa_flags = SA_RESTART;
- sigemptyset(&_entrance_x_sa.sa_mask);
- _entrance_x_sa.sa_flags = 0;
x_ready = 0;
@@ -154,7 +149,12 @@
syslog(LOG_WARNING, "fork() to start X server failed.");
return -1;
case 0:
+ _entrance_x_sa.sa_handler = SIG_IGN;
+ _entrance_x_sa.sa_flags = 0;
+ sigemptyset(&_entrance_x_sa.sa_mask);
sigaction(SIGUSR1, &_entrance_x_sa, NULL);
+ /* FIXME: need to parse command and NOT go thru /bin/sh!!!! */
+ /* why? some /bin/sh's wont pass on this SIGUSR1 thing... */
execl("/bin/sh", "/bin/sh", "-c", x_cmd, NULL);
syslog(LOG_WARNING, "Could not execute X server.");
exit(1);
@@ -167,8 +167,8 @@
usleep(100000);
current_time = ecore_time_get();
- if ((start_time - current_time) > 5.0)
- break;
+ if ((current_time - start_time) > 5.0)
+ break;
}
if (!x_ready)
@@ -520,9 +520,8 @@
/* Manually add signal handler for SIGUSR1 */
_entrance_d_sa.sa_handler = _Entranced_SIGUSR;
- _entrance_x_sa.sa_flags = SA_RESTART;
+ _entrance_d_sa.sa_flags = SA_RESTART;
sigemptyset(&_entrance_d_sa.sa_mask);
- _entrance_x_sa.sa_flags = 0;
sigaction(SIGUSR1, &_entrance_d_sa, NULL);
/* Launch X Server */
-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs