]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
* grub-core/commands/i386/pc/halt.c (grub_halt): Add noreturn attribute.
authorVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Wed, 29 Feb 2012 14:06:39 +0000 (15:06 +0100)
committerVladimir 'phcoder' Serbinenko <phcoder@gmail.com>
Wed, 29 Feb 2012 14:06:39 +0000 (15:06 +0100)
(grub_cmd_halt): Likewise.

ChangeLog
grub-core/commands/i386/pc/halt.c

index 679849158b160ddd0dccbedc5d719223ebe0456e..c1c594fe5aa019431e2abcddc6cb3a6e736be8d8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2012-02-29  Vladimir Serbinenko  <phcoder@gmail.com>
+
+       * grub-core/commands/i386/pc/halt.c (grub_halt): Add noreturn attribute.
+       (grub_cmd_halt): Likewise.
+
 2012-02-29  Vladimir Serbinenko  <phcoder@gmail.com>
 
        * grub-core/lib/i386/relocator16.S: Declare LOCAL(relocator16_end)
index e7c191de3f387ff81886b7c7469898941f560b55..1e7c2c9b3ff4c46deac28e9f98ef3721a372deeb 100644 (file)
@@ -44,7 +44,7 @@ stop (void)
  * Halt the system, using APM if possible. If NO_APM is true, don't use
  * APM even if it is available.
  */
-void 
+void  __attribute__ ((noreturn))
 grub_halt (int no_apm)
 {
   struct grub_bios_int_registers regs;
@@ -97,7 +97,7 @@ grub_halt (int no_apm)
   stop ();
 }
 
-static grub_err_t
+static grub_err_t __attribute__ ((noreturn))
 grub_cmd_halt (grub_extcmd_context_t ctxt,
               int argc __attribute__ ((unused)),
               char **args __attribute__ ((unused)))
@@ -109,7 +109,6 @@ grub_cmd_halt (grub_extcmd_context_t ctxt,
   if (state[0].set)
     no_apm = 1;
   grub_halt (no_apm);
-  return 0;
 }
 
 static grub_extcmd_t cmd;