-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 This looks fine, applying. On Fri, 16 Oct 2009, Steffen Maier wrote:
The support for boot option "nokill" in shutdown by ade8105a8515afee24220fd0cc1199e30c1c3142 did not adapt the standalone version of shutdown (#ifdef AS_SHUTDOWN) so doKill was always 0. Introduce a new command line option "--nokill" and otherwise default to doKill=1. While we're at it also provide a command line option "-P" for poweroff. --- loader/shutdown.c | 11 ++++++++--- 1 files changed, 8 insertions(+), 3 deletions(-) diff --git a/loader/shutdown.c b/loader/shutdown.c index 6a32e79..c733f86 100644 --- a/loader/shutdown.c +++ b/loader/shutdown.c @@ -125,12 +125,17 @@ void shutDown(int doKill, reboot_action rebootAction) { #ifdef AS_SHUTDOWN int main(int argc, char ** argv) { int fd; - int doReboot = 0; + reboot_action rebootAction = HALT; + int doKill = 1; int i = 1; while (i < argc) { if (!strncmp("-r", argv[i], 2)) - doReboot = 1; + rebootAction = REBOOT; + else if (!strncmp("--nokill", argv[i], 8)) + doKill = 0; + else if (!strncmp("-P", argv[i], 2)) + rebootAction = POWEROFF; i++; } @@ -148,7 +153,7 @@ int main(int argc, char ** argv) { dup2(fd, 2); close(fd); - shutDown(0, doReboot ? REBOOT : HALT); + shutDown(doKill, rebootAction); return 0; } #endif
- -- David Cantrell <dcantrell@xxxxxxxxxx>
Red Hat / Honolulu, HI -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkrX6JEACgkQ5hsjjIy1Vkn4FQCgvmbCwpPLrPzBtyPmbaa6cyxE QlQAn00rLV6flP/e+caU1/c8GMyZWrAs =idoN -----END PGP SIGNATURE----- _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list