diff options
| author | Miguel <m.i@gmx.at> | 2018-10-05 23:41:51 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-10-05 23:41:51 +0200 |
| commit | fe8180d88540bfa96595dcc58290de5425e534e3 (patch) | |
| tree | a7a681cdcf013119d121fb17ce3b731763a4a644 /userspace/init.c | |
| parent | 4dbe6a264d7a3bd38ca1ac0921248654a50f1b5e (diff) | |
drunken proggin
Diffstat (limited to 'userspace/init.c')
| -rw-r--r-- | userspace/init.c | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/userspace/init.c b/userspace/init.c index d07942b..645acd9 100644 --- a/userspace/init.c +++ b/userspace/init.c @@ -1,31 +1,38 @@ #include <stdio.h> #include <time.h> #include "put_pixel.h" +#include "newcalls.h" + int main(int argc, char **argv) { // loop forever and spawn shells if the top-shell exits - _execve("/bin/xterm",NULL,NULL); + int fds[2]; + _pipe(fds); - _execve("/bin/vesa",NULL,NULL); int pid=_fork(); if(pid==0) { + _execve("/bin/xterm",NULL,NULL); int pid=_fork(); + if(pid==0) { - _execve("/bin/pain1",NULL,NULL); + _execve("/bin/xterm",NULL,NULL); } else { - _execve("/bin/vesa",NULL,NULL); + _execve("/bin/xterm",NULL,NULL); } } else { + _execve("/bin/xterm",NULL,NULL); + while(1); // block + int pid=_fork(); if(pid==0) { @@ -33,7 +40,8 @@ int main(int argc, char **argv) } else { - _execve("/bin/pain3",NULL,NULL); + _execve("/bin/pain1",NULL,NULL); + //_execve("/bin/pain3",NULL,NULL); } } |
