When creating a new process group, add it to the session.

PiperOrigin-RevId: 216554791
Change-Id: Ia6b7a2e6eaad80a81b2a8f2e3241e93ebc2bda35
This commit is contained in:
Nicolas Lacasse
2018-10-10 10:42:11 -07:00
committed by Shentubot
parent 29cd05a7c6
commit b78552d30e
+3
View File
@@ -367,6 +367,9 @@ func (tg *ThreadGroup) CreateProcessGroup() error {
tg.processGroup.decRefWithParent(oldParentPG)
tg.processGroup = pg
// Add the new process group to the session.
pg.session.processGroups.PushBack(pg)
// Ensure this translation is added to all namespaces.
for ns := tg.pidns; ns != nil; ns = ns.parent {
local := ns.tids[tg.leader]