From 8b65b57472d5086f2c035a09fdb07a40285beb4a Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 28 Jul 2021 14:41:32 +0200 Subject: score: Canonicalize _CPU_Fatal_halt() Move _CPU_Fatal_halt() declaration to and make sure it is a proper declaration of a function which does not return. Fix the type of the error code. If necessary, add the implementation to cpu.c. Implementing _CPU_Fatal_halt() as a function makes it possible to wrap this function for example to fully test _Terminate(). --- cpukit/score/src/interr.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'cpukit/score/src/interr.c') diff --git a/cpukit/score/src/interr.c b/cpukit/score/src/interr.c index fd5a4c92b8..0b4ad1f7f9 100644 --- a/cpukit/score/src/interr.c +++ b/cpukit/score/src/interr.c @@ -21,6 +21,7 @@ #endif #include +#include #include #include #include @@ -36,9 +37,6 @@ void _Terminate( _System_state_Set( SYSTEM_STATE_TERMINATED ); _SMP_Request_shutdown(); _CPU_Fatal_halt( the_source, the_error ); - - /* will not return from this routine */ - while (true); } void _Internal_error( Internal_errors_Core_list core_error ) -- cgit v1.2.3