aboutsummaryrefslogtreecommitdiffstats
path: root/config/tinydns
diff options
context:
space:
mode:
Diffstat (limited to 'config/tinydns')
-rw-r--r--config/tinydns/tinydns.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/tinydns/tinydns.inc b/config/tinydns/tinydns.inc
index 047383ff..5effa10c 100644
--- a/config/tinydns/tinydns.inc
+++ b/config/tinydns/tinydns.inc
@@ -1163,7 +1163,7 @@ function tinydns_dnscache_forwarding_servers($index) {
exec("rm -R {$g['varetc_path']}/dnscache/root/servers/");
exec("/bin/mkdir -p {$g['varetc_path']}/dnscache{$index}/root/servers/");
if (intval($config['version']) >= 6)
- if (file_exists("{$g['varetc_path']}/nameserver_*")) {
+ if (!empty(glob("{$g['varetc_path']}/nameserver_*"))) {
exec("/bin/cat {$g['varetc_path']}/nameserver_* > {$g['varetc_path']}/dnscache{$index}/root/servers/@");
} else {
$fw = fopen("{$g['varetc_path']}/dnscache{$index}/root/servers/@", "w");