mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-03 14:48:57 +00:00
Fix -1 (onetry) fails, exit(2) rather than exit(1) so an error from this
option is distingishable from other errors.
This commit is contained in:
parent
ad0caac41f
commit
5b4742f188
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=48222
@ -295,8 +295,8 @@ static void usage (appname)
|
||||
note (url);
|
||||
note ("");
|
||||
|
||||
warn ("Usage: %s [-c] [-p <port>] [-lf lease-file]", appname);
|
||||
error (" [-pf pidfile] [-1] [interface]");
|
||||
warn ("Usage: %s [-D] [-d] [-p <port>] [-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");
|
||||
|
Loading…
Reference in New Issue
Block a user