Skip to content

Commit

Permalink
Revert "Use clean to cleanup the host file for windows"
Browse files Browse the repository at this point in the history
This reverts commit 3440409.
  • Loading branch information
cfergeau committed Jan 6, 2022
1 parent 1169529 commit f4fd9aa
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions pkg/hosts/hosts.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"
"os"
"regexp"
"runtime"
"sort"
"strings"

Expand Down Expand Up @@ -76,11 +75,6 @@ func (h *Hosts) Add(ip string, hosts []string) error {
if err := h.File.Add(ip, hostEntries...); err != nil {
return err
}
// Only execute clean in case of windows to avoid more than
// 9 domain entry in a single line
if runtime.GOOS == "windows" {
h.File.Clean()
}
return h.File.Flush()
}

Expand Down

0 comments on commit f4fd9aa

Please sign in to comment.