|
|
|
|
|
by CUR10US
5129 days 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. |
|