Commits

Anonymous committed 617a615

Cancel any outstanding protocol timeout when a link goes away. When
the link comes back we will start from scratch with DISCOVER. Stops
pointless attempts to issue packets over a disconnected interface.

Noticed by deraadt@

Comments (0)

Files changed (1)

sbin/dhclient/dhclient.c

-/*	$OpenBSD: dhclient.c,v 1.237 2013/02/18 15:57:08 krw Exp $	*/
+/*	$OpenBSD: dhclient.c,v 1.238 2013/02/19 23:40:25 krw Exp $	*/
 
 /*
  * Copyright 2004 Henning Brauer <henning@openbsd.org>
 			if (ifi->linkstat) {
 				client->state = S_REBOOTING;
 				state_reboot();
+			} else {
+				/* No need to wait for anything but link. */
+				cancel_timeout();
 			}
 		}
 		break;