summaryrefslogtreecommitdiff
path: root/net/isc-dhcp3/files/patch-dhclient.c
diff options
context:
space:
mode:
authorJames E. Housley <jeh@FreeBSD.org>2001-03-24 11:09:53 +0000
committerJames E. Housley <jeh@FreeBSD.org>2001-03-24 11:09:53 +0000
commita9b869c164a828ca228eb4e59a94e440fcc3f939 (patch)
tree60c7fe20558a4b3e29765084860b13a17c7c318c /net/isc-dhcp3/files/patch-dhclient.c
parentUpdate port to version 2.3.9. (diff)
Update to version 3.0.b2.23
Submitted by: Cyrille Lefevre <clefevre@poboxes.com> MAINTAINER
Notes
Notes: svn path=/head/; revision=40312
Diffstat (limited to 'net/isc-dhcp3/files/patch-dhclient.c')
-rw-r--r--net/isc-dhcp3/files/patch-dhclient.c72
1 files changed, 0 insertions, 72 deletions
diff --git a/net/isc-dhcp3/files/patch-dhclient.c b/net/isc-dhcp3/files/patch-dhclient.c
deleted file mode 100644
index 208c0dc23613..000000000000
--- a/net/isc-dhcp3/files/patch-dhclient.c
+++ /dev/null
@@ -1,72 +0,0 @@
---- client/dhclient.c.orig Fri Mar 16 00:12:03 2001
-+++ client/dhclient.c Thu Mar 22 14:57:19 2001
-@@ -78,6 +78,7 @@
- u_int16_t remote_port;
- int no_daemon;
- int save_scripts;
-+int onetry;
- struct string_list *client_env;
- int client_env_count;
-
-@@ -106,6 +107,7 @@
- int no_dhclient_conf = 0;
- int no_dhclient_db = 0;
- int no_dhclient_pid = 0;
-+ int no_dhclient_script = 0;
- char *s;
-
- #ifdef SYSLOG_4_2
-@@ -161,6 +163,13 @@
- usage ();
- path_dhclient_db = argv [i];
- no_dhclient_db = 1;
-+ } else if (!strcmp (argv [i], "-sf")) {
-+ if (++i == argc)
-+ usage ();
-+ client_script_name = argv [i];
-+ no_dhclient_script = 1;
-+ } else if (!strcmp (argv [i], "-1")) {
-+ onetry = 1;
- } else if (!strcmp (argv [i], "-q")) {
- quiet = 1;
- quiet_interface_discovery = 1;
-@@ -224,6 +233,9 @@
- if (!no_dhclient_pid && (s = getenv ("PATH_DHCLIENT_PID"))) {
- path_dhclient_pid = s;
- }
-+ if (!no_dhclient_script && (s = getenv ("PATH_DHCLIENT_SCRIPT"))) {
-+ client_script_name = s;
-+ }
-
- /* first kill of any currently running client */
- if (release_mode) {
-@@ -445,10 +457,12 @@
- log_info (arr);
- log_info (url);
-
-- log_error ("Usage: dhclient [-d] [-D] [-q] [-p <port>] %s",
-+ log_error ("Usage: dhclient [-1dDqr] [-p <port>] %s",
- "[-s server]");
-- log_fatal (" [-lf lease-file] [-pf pid-file]%s",
-- "[-cf config-file] [interface] [-e VAR=val]");
-+ log_error (" [-cf config-file] [-lf lease-file] %s",
-+ "[-pf pid-file]");
-+ log_fatal (" [-sf script-file] [interface] %s",
-+ "[-e VAR=val]");
- }
-
- isc_result_t find_class (struct class **c,
-@@ -1453,6 +1467,13 @@
- /* No leases were available, or what was available didn't work, so
- tell the shell script that we failed to allocate an address,
- and try again later. */
-+ if (onetry) {
-+ if (!quiet)
-+ log_info ("Unable to obtain a lease on first try - %s.",
-+
-+ "exiting");
-+ exit(2);
-+ }
- log_info ("No working leases in persistent database - sleeping.");
- script_init (client, "FAIL", (struct string_list *)0);
- if (client -> alias)