aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/services/dnsmasq
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2016-02-25 09:24:24 +0000
committerFelix Fietkau <nbd@openwrt.org>2016-02-25 09:24:24 +0000
commit5e84051a0f1126a8e984bccd06bcaf093c7ba539 (patch)
tree058080221e0474b127708b582f81847b9e46e0d1 /package/network/services/dnsmasq
parent3064f168639f51b294b06855751f85a4230fba99 (diff)
downloadupstream-5e84051a0f1126a8e984bccd06bcaf093c7ba539.tar.gz
upstream-5e84051a0f1126a8e984bccd06bcaf093c7ba539.tar.bz2
upstream-5e84051a0f1126a8e984bccd06bcaf093c7ba539.zip
dnsmasq: only enable tftp if the tftp root exists
Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 48760
Diffstat (limited to 'package/network/services/dnsmasq')
-rw-r--r--package/network/services/dnsmasq/files/dnsmasq.init3
1 files changed, 2 insertions, 1 deletions
diff --git a/package/network/services/dnsmasq/files/dnsmasq.init b/package/network/services/dnsmasq/files/dnsmasq.init
index db342e7c8e..504c4acf4c 100644
--- a/package/network/services/dnsmasq/files/dnsmasq.init
+++ b/package/network/services/dnsmasq/files/dnsmasq.init
@@ -128,7 +128,8 @@ dnsmasq() {
append_bool "$cfg" dbus "--enable-dbus"
append_bool "$cfg" boguspriv "--bogus-priv"
append_bool "$cfg" expandhosts "--expand-hosts"
- append_bool "$cfg" enable_tftp "--enable-tftp"
+ config_get tftp_root "$cfg" "tftp_root"
+ [ -d "$tftp_root" ] && append_bool "$cfg" enable_tftp "--enable-tftp"
append_bool "$cfg" tftp_no_fail "--tftp-no-fail"
append_bool "$cfg" nonwildcard "--bind-dynamic"
append_bool "$cfg" fqdn "--dhcp-fqdn"