rpms/dhcp/F-13 dhcp-4.1.1-initialization-delay.patch, 1.1, 1.2 dhcp.spec, 1.304, 1.305

Jiří Popelka jpopelka at fedoraproject.org
Mon May 3 14:45:45 UTC 2010


Author: jpopelka

Update of /cvs/pkgs/rpms/dhcp/F-13
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv16580

Modified Files:
	dhcp-4.1.1-initialization-delay.patch dhcp.spec 
Log Message:
* Mon May 03 2010 Jiri Popelka <jpopelka at redhat.com> - 12:4.1.1-21
- Fix the initialization-delay.patch (#587070)


dhcp-4.1.1-initialization-delay.patch:
 dhclient.c |   27 +++++++++++++++++++--------
 1 file changed, 19 insertions(+), 8 deletions(-)

Index: dhcp-4.1.1-initialization-delay.patch
===================================================================
RCS file: /cvs/pkgs/rpms/dhcp/F-13/dhcp-4.1.1-initialization-delay.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- dhcp-4.1.1-initialization-delay.patch	29 Apr 2010 15:24:37 -0000	1.1
+++ dhcp-4.1.1-initialization-delay.patch	3 May 2010 14:45:44 -0000	1.2
@@ -1,21 +1,45 @@
 diff -up dhcp-4.1.1/client/dhclient.c.initialization-delay dhcp-4.1.1/client/dhclient.c
---- dhcp-4.1.1/client/dhclient.c.initialization-delay	2010-04-29 17:02:09.000000000 +0200
-+++ dhcp-4.1.1/client/dhclient.c	2010-04-29 17:03:27.000000000 +0200
-@@ -930,7 +930,7 @@ main(int argc, char **argv) {
- 					/* Set up a timeout to start the
- 					 * initialization process.
+--- dhcp-4.1.1/client/dhclient.c.initialization-delay	2010-05-03 15:16:43.000000000 +0200
++++ dhcp-4.1.1/client/dhclient.c	2010-05-03 15:23:05.000000000 +0200
+@@ -927,11 +927,16 @@ main(int argc, char **argv) {
+ 					do_release(client);
+ 				else {
+ 					client->state = S_INIT;
+-					/* Set up a timeout to start the
+-					 * initialization process.
++					/* Set up a timeout (0-1 second) to
++					 * start the initialization process.
  					 */
 -					tv.tv_sec = cur_time + random() % 5;
-+					tv.tv_sec = cur_time + random() % 1;
- 					tv.tv_usec = 0;
+-					tv.tv_usec = 0;
++					tv.tv_sec = cur_tv.tv_sec;
++					tv.tv_usec = cur_tv.tv_usec;
++					tv.tv_usec += (random() % 100) * 10000;
++					if (tv.tv_usec >= 1000000) {
++						tv.tv_sec += 1;
++						tv.tv_usec -= 1000000;
++					} 
  					add_timeout(&tv, state_reboot,
  						    client, 0, 0);
-@@ -3913,7 +3913,7 @@ isc_result_t dhclient_interface_startup_
+ 				}
+@@ -3911,10 +3916,16 @@ isc_result_t dhclient_interface_startup_
+ 		ip -> flags |= INTERFACE_RUNNING;
+ 		for (client = ip -> client; client; client = client -> next) {
  			client -> state = S_INIT;
- 			/* Set up a timeout to start the initialization
- 			   process. */
+-			/* Set up a timeout to start the initialization
+-			   process. */
 -			tv . tv_sec = cur_time + random () % 5;
-+			tv . tv_sec = cur_time + random () % 1;
- 			tv . tv_usec = 0;
+-			tv . tv_usec = 0;
++			/* Set up a timeout (0-1 second) to
++			 * start the initialization process.
++			 */
++			tv.tv_sec = cur_tv.tv_sec;
++			tv.tv_usec = cur_tv.tv_usec;
++			tv.tv_usec += (random() % 100) * 10000;
++			if (tv.tv_usec >= 1000000) {
++				tv.tv_sec += 1;
++				tv.tv_usec -= 1000000;
++			}
  			add_timeout (&tv, state_reboot, client, 0, 0);
  		}
+ 	}


Index: dhcp.spec
===================================================================
RCS file: /cvs/pkgs/rpms/dhcp/F-13/dhcp.spec,v
retrieving revision 1.304
retrieving revision 1.305
diff -u -p -r1.304 -r1.305
--- dhcp.spec	29 Apr 2010 15:24:37 -0000	1.304
+++ dhcp.spec	3 May 2010 14:45:45 -0000	1.305
@@ -13,7 +13,7 @@
 Summary:  Dynamic host configuration protocol software
 Name:     dhcp
 Version:  %{basever}
-Release:  20%{?dist}
+Release:  21%{?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.
@@ -215,23 +215,25 @@ libdhcpctl and libomapi static libraries
 # Discard unicast Request/Renew/Release/Decline message
 # (unless we set unicast option) and respond with Reply
 # with UseMulticast Status Code option (#573090)
+# (Submitted to dhcp-bugs at isc.org - [ISC-Bugs #21235])
 %patch22 -p1 -b .UseMulticast
 
 # If any of the bound addresses are found to be in use on the link,
 # the dhcpv6 client sends a Decline message to the server
 # as described in section 18.1.7 of RFC-3315 (#559147)
+# (Submitted to dhcp-bugs at isc.org - [ISC-Bugs #21237])
 %patch23 -p1 -b .sendDecline
 
 # In client initiated message exchanges stop retransmission
 # upon reaching the MRD rather than at some point after it (#559153)
+# (Submitted to dhcp-bugs at isc.org - [ISC-Bugs #21238])
 %patch24 -p1 -b .retransmission
 
 # Fill in Elapsed Time Option in Release message (#582939)
 # (Submitted to dhcp-bugs at isc.org - [ISC-Bugs #21171])
 %patch25 -p1 -b .release6-elapsed
 
-# There was a useless 0-4 second delay before sending first DHCPDISCOVER.
-# I didn't remove it at all, but made it 0-1 second. (#587070)
+# Cut down the 0-4 second delay before sending first DHCPDISCOVER (#587070)
 %patch26 -p1 -b .initialization-delay
 
 # Copy in documentation and example scripts for LDAP patch to dhcpd
@@ -516,9 +518,11 @@ fi
 %attr(0644,root,root) %{_mandir}/man3/omapi.3.gz
 
 %changelog
+* Mon May 03 2010 Jiri Popelka <jpopelka at redhat.com> - 12:4.1.1-21
+- Fix the initialization-delay.patch (#587070)
+
 * Thu Apr 29 2010 Jiri Popelka <jpopelka at redhat.com> - 12:4.1.1-20
-- There was a useless 0-4 second delay before sending first DHCPDISCOVER.
-  I didn't remove it at all, but made it 0-1 second. (#587070)
+- Cut down the 0-4 second delay before sending first DHCPDISCOVER (#587070)
 
 * Wed Apr 28 2010 Jiri Popelka <jpopelka at redhat.com> - 12:4.1.1-19
 - Move /etc/NetworkManager/dispatcher.d/10-dhclient script



More information about the scm-commits mailing list