From 5b4742f188e51c83d5027955a817496cadd381ce Mon Sep 17 00:00:00 2001 From: "David E. O'Brien" Date: Fri, 25 Jun 1999 22:28:34 +0000 Subject: [PATCH] Fix -1 (onetry) fails, exit(2) rather than exit(1) so an error from this option is distingishable from other errors. --- contrib/isc-dhcp/client/dhclient.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/isc-dhcp/client/dhclient.c b/contrib/isc-dhcp/client/dhclient.c index a4f0b356ceb9..9ca6e25fb7ca 100644 --- a/contrib/isc-dhcp/client/dhclient.c +++ b/contrib/isc-dhcp/client/dhclient.c @@ -295,8 +295,8 @@ static void usage (appname) note (url); note (""); - warn ("Usage: %s [-c] [-p ] [-lf lease-file]", appname); - error (" [-pf pidfile] [-1] [interface]"); + warn ("Usage: %s [-D] [-d] [-p ] [-lf lease-file]", appname); + error (" [-pf pidfile] [-q] [-1] [interface]"); } void cleanup () @@ -1181,7 +1181,7 @@ void state_panic (ipp) tell the shell script that we failed to allocate an address, and try again later. */ if (onetry) { - exit(1); + exit(2); note ("Unable to obtain a lease on first try - exiting.\n"); } note ("No working leases in persistent database - sleeping.\n");