chiark / gitweb /
dhcp: Send DHCP Request to acquire an IP address
authorPatrik Flykt <patrik.flykt@linux.intel.com>
Mon, 9 Dec 2013 21:43:27 +0000 (23:43 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 12 Dec 2013 16:43:34 +0000 (11:43 -0500)
commite2dfc79f0624dfbfa30156880b31b13510405f54
treecdfd27947556e00e464573e6158b721f089f8523
parent8c00042c939938818365753023ff2d50f984dec6
dhcp: Send DHCP Request to acquire an IP address

Create and send a DHCP Request message reusing already existing parts
of the code. This causes factoring out IP and UDP header creation and
moving next timeout calculation to be done every time in the timer
callback function independent of DHCP state. Also add an exponential
part to the timer calculation, bail out if there are errors while
resending the DHCP message for the sixth or more times.
src/libsystemd-dhcp/dhcp-client.c