4 ms·
Sometimes I don't want to fork, e.g., if there's nothing waiting for input, e.g., the last program in a pipe. prog |prog |exec prog The usual way to do this i
by CUR10US 14y ago
Sometimes I don't want to fork, e.g., if there's nothing waiting for input, e.g., the last program in a pipe.
prog |prog |exec prog
The usual way to do this is to put it in a shell script, then run the shell script. Though it would be nice in some instances, you can't run exec from a shell prompt or you'll exit the shell. I was thinking that if I'm in the kona console, executed from a parent shell, then I could type exec from the console and run programs without forking, because it's not going to cause kona to exit. Wishful thinking.
To stop forking, you would have to add an option to call execve() instead of system() in the kona source.
- silentbicycle 14y agoOh. That wouldn't need much changed to work. I probably won't get to it for a while, but a patch/pull request would be welcome.