32 lines · 692 B · Text
RawDownload
--- /sys/src/9/port/proc.c	Fri May 24 05:35:49 2019+++ ../frontmods/port/proc.c	Fri May 24 05:40:50 2019@@ -622,6 +622,7 @@ 	p->egrp = nil; 	p->fgrp = nil; 	p->rgrp = nil;+	p->sgrp = nil; 	p->pdbg = nil; 	p->fpstate = FPinit; 	p->kp = 0;@@ -1091,6 +1092,7 @@ 	Egrp *egrp; 	Rgrp *rgrp; 	Pgrp *pgrp;+	Sgrp *sgrp; 	Chan *dot; 	void (*pt)(Proc*, int, vlong); @@ -1120,6 +1122,13 @@ 		closeegrp(egrp); 	if(rgrp != nil) 		closergrp(rgrp);+	/* sgrp is nilled out here because closefgrp may need srvclose */+	qlock(&up->debug);+	sgrp = up->sgrp;+	up->sgrp = nil;+	qunlock(&up->debug);+	if(sgrp != nil)+		closesgrp(sgrp); 	if(dot != nil) 		cclose(dot); 	if(pgrp != nil)