https://www.win.tue.nl/~aeb/linux/lk/lk-10.html
Shortly, there is only one process group which is foreground, you can get it with tcgetpgrp(fd) or set it with tcsetpgrp(fd,pgrp). To setup process group of the process use setpgid(pid, pgid);
https://www.win.tue.nl/~aeb/linux/lk/lk-10.html
Shortly, there is only one process group which is foreground, you can get it with tcgetpgrp(fd) or set it with tcsetpgrp(fd,pgrp). To setup process group of the process use setpgid(pid, pgid);