[rtems commit] pc386/startup/bsp_fatal_halt.c: Fix noreturn does return warning

Joel Sherrill joel at rtems.org
Thu Mar 10 16:45:12 UTC 2016


Module:    rtems
Branch:    master
Commit:    6db5ea03c359c6230fdc53e0b035f25d9e0cf1f3
Changeset: http://git.rtems.org/rtems/commit/?id=6db5ea03c359c6230fdc53e0b035f25d9e0cf1f3

Author:    Joel Sherrill <joel at rtems.org>
Date:      Wed Mar  9 11:25:13 2016 -0600

pc386/startup/bsp_fatal_halt.c: Fix noreturn does return warning

---

 c/src/lib/libbsp/i386/pc386/startup/bsp_fatal_halt.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/c/src/lib/libbsp/i386/pc386/startup/bsp_fatal_halt.c b/c/src/lib/libbsp/i386/pc386/startup/bsp_fatal_halt.c
index 3e4f263..07bbd79 100644
--- a/c/src/lib/libbsp/i386/pc386/startup/bsp_fatal_halt.c
+++ b/c/src/lib/libbsp/i386/pc386/startup/bsp_fatal_halt.c
@@ -18,4 +18,7 @@ void _CPU_Fatal_halt(uint32_t source, uint32_t error)
          : "=r" ((error))
          : "0" ((error))
   );
+  #ifdef __GNUC__
+    __builtin_unreachable();
+  #endif
 }



More information about the vc mailing list