Package: dhcp3-client Version: 3.1.1-1 Tags: patch User: [EMAIL PROTECTED] Usertags: origin-ubuntu ubuntu-patch intrepid
When "dhclient -1" fails to get an address, it does not call dhclient-script FAIL as it does without -1. This breaks e. g. the avahi-autoipd invocation in this mode (which dhcdbd uses by default). Attached patch was applied in Ubuntu a while ago, and it fixes the bug. Now avahi-autoipd assigns an IPv4LL address for timed out DHCP requests correctly. Thanks, Martin -- Martin Pitt | http://www.piware.de Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)
#! /bin/sh /usr/share/dpatch/dpatch-run
## dhclient-onetry-call-clientscript.dpatch by Martin Pitt <[EMAIL PROTECTED]>
##
## DP: Call 'dhclient-script FAIL' when failing to get an address also when
## DP: operating in oneshot mode (-1). This fixes avahi-autoipd invocation
## DP: through dhcdbd.
@DPATCH@
diff -urNad dhcp3-3.0.4~/client/dhclient.c dhcp3-3.0.4/client/dhclient.c
--- dhcp3-3.0.4~/client/dhclient.c 2006-12-01 14:18:30.000000000 +0100
+++ dhcp3-3.0.4/client/dhclient.c 2006-12-01 14:18:45.000000000 +0100
@@ -1556,6 +1556,8 @@
if (!quiet)
log_info ("Unable to obtain a lease on first try.%s",
" Exiting.");
+ script_init (client, "FAIL", (struct string_list *)0);
+ script_go (client);
exit (2);
}
signature.asc
Description: Digital signature

