From 03bed023938374d5505922ab3af9521a8be2d524 Mon Sep 17 00:00:00 2001 From: Sean Cross Date: Mon, 5 Apr 2021 18:19:33 +0800 Subject: [PATCH] xous: make `terminate_process` divergent This allows for terminating a process when something goes wrong. Signed-off-by: Sean Cross --- xous-rs/src/syscall.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xous-rs/src/syscall.rs b/xous-rs/src/syscall.rs index 4b593a52d..225ff5093 100644 --- a/xous-rs/src/syscall.rs +++ b/xous-rs/src/syscall.rs @@ -1318,8 +1318,9 @@ pub fn send_message(connection: CID, message: Message) -> core::result::Result ! { rsyscall(SysCall::TerminateProcess).expect("terminate_process returned an error"); + panic!("process didn't terminate"); } /// Return execution to the kernel. This function may return at any time,