From 94505ae6c501d04b7a581c78998b4481bea2a562 Mon Sep 17 00:00:00 2001 From: bunnie Date: Tue, 27 Apr 2021 00:52:52 +0800 Subject: [PATCH] improve some error messages --- services/xous-names/src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/xous-names/src/main.rs b/services/xous-names/src/main.rs index 9dc067749..9e04a072d 100644 --- a/services/xous-names/src/main.rs +++ b/services/xous-names/src/main.rs @@ -103,7 +103,7 @@ fn xmain() -> ! { info!("deterministic timeout done"); response = api::Return::Failure } - buffer.replace(response).unwrap(); + buffer.replace(response).expect("Register can't serialize return value"); } Some(api::Opcode::Lookup) => { let mem = msg.body.memory_message_mut().unwrap(); @@ -152,7 +152,7 @@ fn xmain() -> ! { }; response = api::Return::AuthenticateRequest(auth_request) // this code just exists to exercise the return path } - buffer.replace(response).unwrap(); + buffer.replace(response).expect("Lookup can't serialize return value"); } Some(api::Opcode::AuthenticatedLookup) => { let mem = msg.body.memory_message_mut().unwrap();