Browse Source

terminal: set initial TTY process group

K. Lange 2 years ago
parent
commit
8787fe1550
1 changed files with 2 additions and 0 deletions
  1. 2 0
      apps/terminal.c

+ 2 - 0
apps/terminal.c

@@ -2484,6 +2484,8 @@ int main(int argc, char ** argv) {
 		dup2(fd_slave, 1);
 		dup2(fd_slave, 2);
 
+		tcsetpgrp(STDIN_FILENO, getpid());
+
 		/* Set the TERM environment variable. */
 		putenv("TERM=toaru");