From 4b1b0ec9e61dcf02dc7a79e504ca3eae4a3b4b53 Mon Sep 17 00:00:00 2001 From: Manuel Stocker Date: Sun, 21 Oct 2018 15:59:37 +0200 Subject: Use filepath when manipulating file paths (#2221) Automatically submitted. --- plugin/file/setup.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'plugin/file/setup.go') diff --git a/plugin/file/setup.go b/plugin/file/setup.go index 86eef6b96..5c371babc 100644 --- a/plugin/file/setup.go +++ b/plugin/file/setup.go @@ -2,7 +2,7 @@ package file import ( "os" - "path" + "path/filepath" "time" "github.com/coredns/coredns/core/dnsserver" @@ -71,8 +71,8 @@ func fileParse(c *caddy.Controller) (Zones, error) { origins = args } - if !path.IsAbs(fileName) && config.Root != "" { - fileName = path.Join(config.Root, fileName) + if !filepath.IsAbs(fileName) && config.Root != "" { + fileName = filepath.Join(config.Root, fileName) } reader, err := os.Open(fileName) -- cgit v1.2.3