summaryrefslogtreecommitdiffhomepage
path: root/pkg/sentry/kernel/task_start.go
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2019-08-02 21:14:10 +0000
committergVisor bot <gvisor-bot@google.com>2019-08-02 21:14:10 +0000
commit7ddd7ef41709212d846dd6da1f8f718397ce36a1 (patch)
tree8cddc0b33872502933063052936fdba712bb2167 /pkg/sentry/kernel/task_start.go
parent15041d177271e6373941d372b8bd2e29db28b125 (diff)
parentb6a5b950d28e0b474fdad160b88bc15314cf9259 (diff)
Merge b6a5b950 (automated)
Diffstat (limited to 'pkg/sentry/kernel/task_start.go')
-rw-r--r--pkg/sentry/kernel/task_start.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/sentry/kernel/task_start.go b/pkg/sentry/kernel/task_start.go
index d60cd62c7..ae6fc4025 100644
--- a/pkg/sentry/kernel/task_start.go
+++ b/pkg/sentry/kernel/task_start.go
@@ -172,9 +172,10 @@ func (ts *TaskSet) newTask(cfg *TaskConfig) (*Task, error) {
if parentPG := tg.parentPG(); parentPG == nil {
tg.createSession()
} else {
- // Inherit the process group.
+ // Inherit the process group and terminal.
parentPG.incRefWithParent(parentPG)
tg.processGroup = parentPG
+ tg.tty = t.parent.tg.tty
}
}
tg.tasks.PushBack(t)