aboutsummaryrefslogtreecommitdiffstats
path: root/package/network
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2016-01-25 17:47:22 +0000
committerJo-Philipp Wich <jow@openwrt.org>2016-01-25 17:47:22 +0000
commitd8da5c5630928893122330f3042523438f5e2e3f (patch)
treebfa4fe377347c526a93a13699d8c96e1624e6e7b /package/network
parent565570cfd5dcd11bacd0e7a36d2abb0d6ea670b5 (diff)
downloadupstream-d8da5c5630928893122330f3042523438f5e2e3f.tar.gz
upstream-d8da5c5630928893122330f3042523438f5e2e3f.tar.bz2
upstream-d8da5c5630928893122330f3042523438f5e2e3f.zip
dnsmasq: Don't add local hostname if ula prefix is not specified
Commit 6a7e56b adds support for adding local hostname for own lan ula adress but if ula prefix is not specified results into an invalid config (address=/OpenWrt.lan/1) causing dnsmasq not to start up. Use lanaddr6 when adding local hostname as the lan ula address is constructed based on the UCI parameters ip6hint and ip6ifaceid and thus not always ula prefix suffixed with 1 Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> SVN-Revision: 48495
Diffstat (limited to 'package/network')
-rw-r--r--package/network/services/dnsmasq/Makefile2
-rw-r--r--package/network/services/dnsmasq/files/dnsmasq.init4
2 files changed, 3 insertions, 3 deletions
diff --git a/package/network/services/dnsmasq/Makefile b/package/network/services/dnsmasq/Makefile
index de0237b314..89799eec6b 100644
--- a/package/network/services/dnsmasq/Makefile
+++ b/package/network/services/dnsmasq/Makefile
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=dnsmasq
PKG_VERSION:=2.75
-PKG_RELEASE:=4
+PKG_RELEASE:=5
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq
diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init
index efc96273a2..db342e7c8e 100644
--- a/package/network/services/dnsmasq/files/dnsmasq.init
+++ b/package/network/services/dnsmasq/files/dnsmasq.init
@@ -609,11 +609,11 @@ start_service() {
dhcp_domain_add "" "$hostname" "$lanaddr"
}
- network_get_ipaddrs6 lanaddr6 "lan" && {
+ [ -n "$ulaprefix" ] && network_get_ipaddrs6 lanaddr6 "lan" && {
for lanaddr6 in $lanaddr6; do
case "$lanaddr6" in
"${ulaprefix%%:/*}"*)
- dhcp_domain_add "" "$hostname" "${ulaprefix%%/*}1"
+ dhcp_domain_add "" "$hostname" "$lanaddr6"
;;
esac
done