git: 9front

Download patch

ref: 4f1544b0221f59f8419bb115ee7c7e6f385477ef
parent: aada916f1e8d7fecc695c41d914bcad1784c4e63
author: cinap_lenrek <cinap_lenrek@centraldogma>
date: Tue Dec 13 11:10:37 EST 2011

killbig(): fix crash if no process could be found

--- a/sys/src/9/port/proc.c
+++ b/sys/src/9/port/proc.c
@@ -1514,7 +1514,8 @@
 			max = l;
 		}
 	}
-
+	if(kp == 0)
+		return;
 	print("%lud: %s killed: %s\n", kp->pid, kp->text, why);
 	for(p = procalloc.arena; p < ep; p++) {
 		if(p->state == Dead || p->kp)
--