aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Dedecker <dedeckeh@gmail.com>2018-06-11 11:17:52 +0200
committerHans Dedecker <dedeckeh@gmail.com>2018-06-11 22:30:38 +0200
commitc0763f08a5416ce0424dff64e8c75965cf708db0 (patch)
tree0ecb4dd6173670c7f771fd2575d75cf8768a84ff
parente6c17aa21912da9b988b57b75e50228eb7e84115 (diff)
downloadupstream-c0763f08a5416ce0424dff64e8c75965cf708db0.tar.gz
upstream-c0763f08a5416ce0424dff64e8c75965cf708db0.tar.bz2
upstream-c0763f08a5416ce0424dff64e8c75965cf708db0.zip
dnsmasq: fix confdir option processing (FS#1572)
Fix condir option processing allowing to use the format "<directory>[,<file-extension>......]," as documented on the dnsmasq man page which previously resulted into bogus dir being created. Signed-off-by: Hans Dedecker <dedeckeh@gmail.com>
-rw-r--r--package/network/services/dnsmasq/Makefile2
-rw-r--r--package/network/services/dnsmasq/files/dnsmasq.init3
2 files changed, 3 insertions, 2 deletions
diff --git a/package/network/services/dnsmasq/Makefile b/package/network/services/dnsmasq/Makefile
index 7fa61ad04f..bb68a67296 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.80test2
-PKG_RELEASE:=1
+PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq/test-releases
diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init
index 2c71a777c3..4906df9ce4 100644
--- a/package/network/services/dnsmasq/files/dnsmasq.init
+++ b/package/network/services/dnsmasq/files/dnsmasq.init
@@ -941,8 +941,9 @@ dnsmasq_start()
xappend "--addn-hosts=$(dirname $HOSTFILE)"
config_get dnsmasqconfdir "$cfg" confdir "/tmp/dnsmasq.d"
- [ ! -d "$dnsmasqconfdir" ] && mkdir -p $dnsmasqconfdir
xappend "--conf-dir=$dnsmasqconfdir"
+ dnsmasqconfdir="${dnsmasqconfdir%%,*}"
+ [ ! -d "$dnsmasqconfdir" ] && mkdir -p $dnsmasqconfdir
xappend "--user=dnsmasq"
xappend "--group=dnsmasq"
echo >> $CONFIGFILE_TMP