From 8eecb3717ad952431df44d41ac7aa6348bcd742f Mon Sep 17 00:00:00 2001 From: Andrew Boie Date: Wed, 22 Jan 2020 11:18:30 -0800 Subject: [PATCH] samples: shared_mem: fix exception printouts Enable CONFIG_TEST so that we get the necessary defines for console output when a fatal error happens, as well as assertion checking. Remove an unnecessary self-abort in main(), this causes an assert to fail. Letting main() return does the same thing, more gracefully. Signed-off-by: Andrew Boie --- samples/userspace/shared_mem/prj.conf | 1 + samples/userspace/shared_mem/src/main.c | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/samples/userspace/shared_mem/prj.conf b/samples/userspace/shared_mem/prj.conf index 90b88349b6f..b582b76a869 100644 --- a/samples/userspace/shared_mem/prj.conf +++ b/samples/userspace/shared_mem/prj.conf @@ -1 +1,2 @@ +CONFIG_TEST=y CONFIG_USERSPACE=y diff --git a/samples/userspace/shared_mem/src/main.c b/samples/userspace/shared_mem/src/main.c index 45748526790..671efb99c2d 100644 --- a/samples/userspace/shared_mem/src/main.c +++ b/samples/userspace/shared_mem/src/main.c @@ -161,8 +161,6 @@ void main(void) k_thread_start(&ct_thread); k_sem_give(&allforone); printk("CT thread started\n"); - k_thread_abort(k_current_get()); - }