diff options
Diffstat (limited to 'core/restart_windows.go')
-rw-r--r-- | core/restart_windows.go | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/core/restart_windows.go b/core/restart_windows.go deleted file mode 100644 index 8a0805a19..000000000 --- a/core/restart_windows.go +++ /dev/null @@ -1,31 +0,0 @@ -package core - -import "log" - -// Restart restarts CoreDNS forcefully using newCorefile, -// or, if nil, the current/existing Corefile is reused. -func Restart(newCorefile Input) error { - log.Println("[INFO] Restarting") - - if newCorefile == nil { - corefileMu.Lock() - newCorefile = corefile - corefileMu.Unlock() - } - - wg.Add(1) // barrier so Wait() doesn't unblock - - err := Stop() - if err != nil { - return err - } - - err = Start(newCorefile) - if err != nil { - return err - } - - wg.Done() // take down our barrier - - return nil -} |