Date: Fri, 17 Aug 2012 16:00:18 GMT From: dfilter@FreeBSD.ORG (dfilter service) To: freebsd-bugs@FreeBSD.org Subject: Re: bin/166656: commit references a PR Message-ID: <201208171600.q7HG0IQE064727@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/166656; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: bin/166656: commit references a PR Date: Fri, 17 Aug 2012 15:53:54 +0000 (UTC) Author: jhb Date: Fri Aug 17 15:53:43 2012 New Revision: 239356 URL: http://svn.freebsd.org/changeset/base/239356 Log: Fix dhclient to properly exit and teardown the configured lease when link is lost. devd will start a new dhclient instance when link is restored. PR: bin/166656 Submitted by: Peter Jeremy (mostly) Reviewed by: brooks (earlier version from Peter) MFC after: 1 month Modified: head/sbin/dhclient/dhclient.c Modified: head/sbin/dhclient/dhclient.c ============================================================================== --- head/sbin/dhclient/dhclient.c Fri Aug 17 14:22:56 2012 (r239355) +++ head/sbin/dhclient/dhclient.c Fri Aug 17 15:53:43 2012 (r239356) @@ -278,6 +278,11 @@ routehandler(struct protocol *p) ifi->name); goto die; } + if (!interface_link_status(ifi->name)) { + warning("Interface %s is down, dhclient exiting", + ifi->name); + goto die; + } break; case RTM_IFANNOUNCE: ifan = (struct if_announcemsghdr *)rtm; @@ -316,6 +321,8 @@ routehandler(struct protocol *p) die: script_init("FAIL", NULL); + if (ifi->client->active) + script_write_params("old_", ifi->client->active); if (ifi->client->alias) script_write_params("alias_", ifi->client->alias); script_go(); _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201208171600.q7HG0IQE064727>