diff options
author | Karel Zak | 2006-12-07 00:25:37 +0100 |
---|---|---|
committer | Karel Zak | 2006-12-07 00:25:37 +0100 |
commit | 5c36a0eb7cdb0360f9afd5d747c321f423b35984 (patch) | |
tree | 147599a77eaff2b5fbc0d389e89d2b51602326c0 /sys-utils/ctrlaltdel.c | |
parent | Imported from util-linux-2.8 tarball. (diff) | |
download | kernel-qcow2-util-linux-5c36a0eb7cdb0360f9afd5d747c321f423b35984.tar.gz kernel-qcow2-util-linux-5c36a0eb7cdb0360f9afd5d747c321f423b35984.tar.xz kernel-qcow2-util-linux-5c36a0eb7cdb0360f9afd5d747c321f423b35984.zip |
Imported from util-linux-2.9i tarball.
Diffstat (limited to 'sys-utils/ctrlaltdel.c')
-rw-r--r-- | sys-utils/ctrlaltdel.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys-utils/ctrlaltdel.c b/sys-utils/ctrlaltdel.c index e5565d704..c754fd058 100644 --- a/sys-utils/ctrlaltdel.c +++ b/sys-utils/ctrlaltdel.c @@ -7,24 +7,24 @@ #include <stdio.h> #include <unistd.h> #include <string.h> - -int reboot(int magic, int magictoo, int flag); +#include "linux_reboot.h" int main(int argc, char *argv[]) { if(geteuid()) { - fprintf(stderr, "You must be root to set the Ctrl-Alt-Del behaviour.\n"); + fprintf(stderr, + "You must be root to set the Ctrl-Alt-Del behaviour.\n"); exit(1); } if(argc == 2 && !strcmp("hard", argv[1])) { - if(reboot(0xfee1dead, 672274793, 0x89abcdef) < 0) { + if(my_reboot(LINUX_REBOOT_CMD_CAD_ON) < 0) { perror("ctrlaltdel: reboot"); exit(1); } } else if(argc == 2 && !strcmp("soft", argv[1])) { - if(reboot(0xfee1dead, 672274793, 0) < 0) { + if(my_reboot(LINUX_REBOOT_CMD_CAD_OFF) < 0) { perror("ctrlaltdel: reboot"); exit(1); } |