Enlightenment CVS committal

Author  : essiene
Project : e17
Module  : apps/entrance

Dir     : e17/apps/entrance/src/daemon


Modified Files:
        entranced_display.c 


Log Message:
- Commit Entrance shell utilization patches from Eugen Minciu... they work like 
a charm :)
- Update TODO

===================================================================
RCS file: /cvs/e/e17/apps/entrance/src/daemon/entranced_display.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- entranced_display.c 1 Aug 2006 05:30:58 -0000       1.2
+++ entranced_display.c 31 Aug 2006 14:37:37 -0000      1.3
@@ -124,6 +124,11 @@
    double start_time;
    char x_cmd[PATH_MAX];
 
+   int i;
+   char *x_cmd_argv[32]; 
+
+   for (i=0;i<32;i++) x_cmd_argv[i]=NULL;
+
    /* Ecore_Exe *x_exe; */
    pid_t xpid;
 
@@ -160,9 +165,15 @@
         _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);
+
+       x_cmd_argv[0]=strtok(x_cmd," ");
+       i=1;
+
+       while ((x_cmd_argv[i]=strtok(NULL," "))!=NULL) {
+          i++;
+       }
+
+        execvp(x_cmd_argv[0], x_cmd_argv);
         syslog(LOG_WARNING, "Could not execute X server.");
         exit(1);
      default:



-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to