* We store the ID of the controlling terminal and the foreground process

group ID with the session and let the terminal update them.
* Added an "orphaned" flag to the process_group structure and code to
  maintain it.
* Handle the death of a controlling process correctly: The
  foreground process group gets a SIGHUP and all newly-orphaned process
  groups containing at least one stopped processes are sent
  SIGHUP+SIGCONT.
* The tty handles the O_NOCTTY flag correctly, now.
* The tty handles reads/writes from processes from other sessions
  correctly, now.
* Handle tcsetpgrp() from background processes correctly.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22187 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2007-09-06 02:16:25 +00:00
parent df716df51d
commit 923efaa872
7 changed files with 248 additions and 16 deletions
+3
View File
@@ -38,6 +38,9 @@ int32 team_used_teams(void);
void team_set_job_control_state(struct team* team, job_control_state newState,
int signal, bool threadsLocked);
void team_set_controlling_tty(int32 index);
int32 team_get_controlling_tty();
status_t team_set_foreground_process_group(int32 ttyIndex, pid_t processGroup);
status_t start_watching_team(team_id team, void (*hook)(team_id, void *),
void *data);