summaryrefslogtreecommitdiff
path: root/src/kernel/proc.c
diff options
context:
space:
mode:
authordzwdz2023-01-24 13:53:44 +0100
committerdzwdz2023-01-24 13:53:44 +0100
commitba2f957dd39a44e0828ab4efd809d36d704fd537 (patch)
treecadd70d806481fee77f7b5922c746e40d458046e /src/kernel/proc.c
parent1e2f807b30cc94fc6dc9fcb24f3e1675fe147439 (diff)
kernel/procfs: allow interrupting processes
Diffstat (limited to 'src/kernel/proc.c')
-rwxr-xr-xsrc/kernel/proc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/kernel/proc.c b/src/kernel/proc.c
index d8c7e57..b49b645 100755
--- a/src/kernel/proc.c
+++ b/src/kernel/proc.c
@@ -196,8 +196,8 @@ void process_kill(struct process *p, int ret) {
process_transition(p, PS_TOMBSTONE);
}
}
- if (p == process_first) {
- assert(!p->child);
+ if (p == process_first && p->child) {
+ _panic("init killed prematurely");
}
process_tryreap(p);