1 --- dhcp-3.0.5/client/dhclient.c.decline 2007-03-30 15:29:58.000000000 -0400
2 +++ dhcp-3.0.5/client/dhclient.c 2007-03-30 15:50:25.000000000 -0400
6 struct client_state *client = cpp;
7 + enum dhcp_state init_state = client->state;
9 ASSERT_STATE(state, S_INIT);
12 client -> first_sending = cur_time;
13 client -> interval = client -> config -> initial_interval;
15 - /* Add an immediate timeout to cause the first DHCPDISCOVER packet
17 - send_discover (client);
18 + if (init_state != S_DECLINED) {
19 + /* Add an immediate timeout to cause the first DHCPDISCOVER packet
21 + send_discover(client);
23 + /* We've received an OFFER and it has been DECLINEd by dhclient-script.
24 + * wait for a random time between 1 and backoff_cutoff seconds before
26 + add_timeout(cur_time + ((1 + (random() >> 2)) % client->config->backoff_cutoff), send_discover, client, 0, 0);
30 /* state_selecting is called when one or more DHCPOFFER packets have been
32 send_decline (client);
33 destroy_client_lease (client -> new);
34 client -> new = (struct client_lease *)0;
35 + client -> state = S_DECLINED;
46 client -> state = S_INIT;
47 --- dhcp-3.0.5/includes/dhcpd.h.decline 2007-03-30 15:30:14.000000000 -0400
48 +++ dhcp-3.0.5/includes/dhcpd.h 2007-03-30 15:50:53.000000000 -0400
58 /* Authentication and BOOTP policy possibilities (not all values work