[dhcp] dhclient: rename our -I option to -C as upstream now uses -I

Jiří Popelka jpopelka at fedoraproject.org
Wed Feb 19 18:02:11 UTC 2014


commit 2ade8d85a35edcea54e6dbf1fcf746236313aeb5
Author: Jiri Popelka <jpopelka at redhat.com>
Date:   Wed Feb 19 19:02:32 2014 +0100

    dhclient: rename our -I option to -C as upstream now uses -I

 dhcp-dhclient-options.patch |   20 ++++++++++----------
 dhcp.spec                   |    5 ++++-
 2 files changed, 14 insertions(+), 11 deletions(-)
---
diff --git a/dhcp-dhclient-options.patch b/dhcp-dhclient-options.patch
index 00e0bb1..74270c6 100644
--- a/dhcp-dhclient-options.patch
+++ b/dhcp-dhclient-options.patch
@@ -42,7 +42,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.8.options dhcp-4.3.0a1/client/dhclient.8
 +.B -B
 +]
 +[
-+.B -I
++.B -C
 +.I dhcp-client-identifier
 +]
 +[
@@ -80,7 +80,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.8.options dhcp-4.3.0a1/client/dhclient.8
 +broadcast replies.
 +
 +.TP
-+.BI \-I\ <dhcp-client-identifier>
++.BI \-C\ <dhcp-client-identifier>
 +Specify the dhcp-client-identifier option to send to the DHCP server.
 +
 +.TP
@@ -185,14 +185,14 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
  		} else if (!strcmp(argv[i], "--version")) {
  			log_info("isc-dhclient-%s", PACKAGE_VERSION);
  			exit(0);
-+		} else if (!strcmp(argv[i], "-I")) {
++		} else if (!strcmp(argv[i], "-C")) {
 +			if ((++i == argc) || (argv[i] == NULL) || (*(argv[i])=='\0')) {
 +				usage();
 +				exit(1);
 +			}
 +
 +			if (strlen(argv[i]) >= DHCP_MAX_OPTION_LEN) {
-+				log_error("-I option dhcp-client-identifier string \"%s\" is too long - maximum length is: %d", argv[i], DHCP_MAX_OPTION_LEN-1);
++				log_error("-C option dhcp-client-identifier string \"%s\" is too long - maximum length is: %d", argv[i], DHCP_MAX_OPTION_LEN-1);
 +				exit(1);
 +			}
 +
@@ -279,7 +279,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
 +		arg_conf_len = asprintf(&arg_conf, "send dhcp-client-identifier \"%s\";", dhcp_client_identifier_arg);
 +
 +		if ((arg_conf == 0) || (arg_conf_len <= 0))
-+			log_fatal("Unable to send -I option dhcp-client-identifier");
++			log_fatal("Unable to send -C option dhcp-client-identifier");
 +	}
 +
 +	if ((dhcp_host_name_arg != NULL) && (*dhcp_host_name_arg != '\0')) {
@@ -376,7 +376,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
 +		if (arg_conf_len == 0)
 +			if ((arg_conf_len = strlen(arg_conf)) == 0)
 +				/* huh ? cannot happen ! */
-+				log_fatal("Unable to process -I/-H/-F/-timeout/-V/-R configuration arguments");
++				log_fatal("Unable to process -C/-H/-F/-timeout/-V/-R configuration arguments");
 +
 +		/* parse the extra dhclient.conf configuration arguments
 +		 * into top level config: */
@@ -384,10 +384,10 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
 +		const char *val = NULL;
 +		int token;
 +
-+		status = new_parse(&cfile, -1, arg_conf, arg_conf_len, "extra dhclient -I/-H/-F/-timeout/-V/-R configuration arguments", 0);
++		status = new_parse(&cfile, -1, arg_conf, arg_conf_len, "extra dhclient -C/-H/-F/-timeout/-V/-R configuration arguments", 0);
 +
 +		if ((status != ISC_R_SUCCESS) || (cfile -> warnings_occurred))
-+			log_fatal("Cannot parse -I/-H/-F/-timeout/-V/-R configuration arguments !");
++			log_fatal("Cannot parse -C/-H/-F/-timeout/-V/-R configuration arguments !");
 +		/* more detailed parse failures will be logged */
 +
 +		do {
@@ -399,7 +399,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
 +		} while (1);
 +
 +		if (cfile -> warnings_occurred)
-+			log_fatal("Cannot parse -I/-H/-F/-timeout/-V/-R configuration arguments !");
++			log_fatal("Cannot parse -C/-H/-F/-timeout/-V/-R configuration arguments !");
 +		end_parse(&cfile);
 +
 +		if (timeout_arg) {
@@ -431,7 +431,7 @@ diff -up dhcp-4.3.0a1/client/dhclient.c.options dhcp-4.3.0a1/client/dhclient.c
  		  "                [-s server-addr] [-cf config-file] "
  		  "[-lf lease-file]\n"
  		  "                [-pf pid-file] [--no-pid] [-e VAR=val]\n"
-+		  "                [-I <dhcp-client-identifier>] [-B]\n"
++		  "                [-C <dhcp-client-identifier>] [-B]\n"
 +		  "                [-H <host-name> | -F <fqdn.fqdn>] [-timeout <timeout>]\n"
 +		  "                [-V <vendor-class-identifier>]\n"
 +		  "                [-R <request option list>]\n"
diff --git a/dhcp.spec b/dhcp.spec
index 6d2b61e..3008433 100644
--- a/dhcp.spec
+++ b/dhcp.spec
@@ -18,7 +18,7 @@
 Summary:  Dynamic host configuration protocol software
 Name:     dhcp
 Version:  4.3.0
-Release:  5%{?dist}
+Release:  6%{?dist}
 # NEVER CHANGE THE EPOCH on this package.  The previous maintainer (prior to
 # dcantrell maintaining the package) made incorrect use of the epoch and
 # that's why it is at 12 now.  It should have never been used, but it was.
@@ -603,6 +603,9 @@ done
 
 
 %changelog
+* Wed Feb 19 2014 Jiri Popelka <jpopelka at redhat.com> - 12:4.3.0-6
+- dhclient: rename our -I option to -C as upstream now uses -I
+
 * Wed Feb 19 2014 Jiri Popelka <jpopelka at redhat.com> - 12:4.3.0-5
 - dhclient-script: don't flush all addresses, just the used one
 


More information about the scm-commits mailing list