371309
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
371309
From: Peter Jones <pjones@redhat.com>
371309
Date: Fri, 31 Aug 2018 16:42:03 -0400
371309
Subject: [PATCH] Make "reset" an alias for the "reboot" command.
371309
371309
I'm really tired of half the tools I get to use having one and the other half
371309
having the other.
371309
371309
Signed-off-by: Peter Jones <pjones@redhat.com>
371309
---
371309
 grub-core/commands/reboot.c | 11 +++++++----
371309
 1 file changed, 7 insertions(+), 4 deletions(-)
371309
371309
diff --git a/grub-core/commands/reboot.c b/grub-core/commands/reboot.c
371309
index 46d364c99a9..f5cc2283636 100644
371309
--- a/grub-core/commands/reboot.c
371309
+++ b/grub-core/commands/reboot.c
371309
@@ -32,15 +32,18 @@ grub_cmd_reboot (grub_command_t cmd __attribute__ ((unused)),
371309
   grub_reboot ();
371309
 }
371309
 
371309
-static grub_command_t cmd;
371309
+static grub_command_t reboot_cmd, reset_cmd;
371309
 
371309
 GRUB_MOD_INIT(reboot)
371309
 {
371309
-  cmd = grub_register_command ("reboot", grub_cmd_reboot,
371309
-			       0, N_("Reboot the computer."));
371309
+  reboot_cmd = grub_register_command ("reboot", grub_cmd_reboot,
371309
+				      0, N_("Reboot the computer."));
371309
+  reset_cmd = grub_register_command ("reset", grub_cmd_reboot,
371309
+				     0, N_("Reboot the computer."));
371309
 }
371309
 
371309
 GRUB_MOD_FINI(reboot)
371309
 {
371309
-  grub_unregister_command (cmd);
371309
+  grub_unregister_command (reboot_cmd);
371309
+  grub_unregister_command (reset_cmd);
371309
 }