-
Notifications
You must be signed in to change notification settings - Fork 8
Closed
Description
We are getting some crashes on OSX.
==> default: Issue executing goodhosts CLI: panic: runtime error: slice bounds out of range [381:379]
==> default:
==> default: goroutine 1 [running]:
==> default: github.com/goodhosts/hostsfile.(*Hosts).removeByPosition(...)
==> default: /home/runner/go/pkg/mod/github.com/goodhosts/[email protected]/hosts.go:297
==> default: github.com/goodhosts/hostsfile.(*Hosts).combineIp(0xc0000d9ac8, 0xc0000145e0, 0x7)
==> default: /home/runner/go/pkg/mod/github.com/goodhosts/[email protected]/hosts.go:285 +0x582
==> default: github.com/goodhosts/hostsfile.(*Hosts).RemoveDuplicateIps(0xc0000d9ac8)
==> default: /home/runner/go/pkg/mod/github.com/goodhosts/[email protected]/hosts.go:224 +0x1f3
==> default: github.com/goodhosts/hostsfile.(*Hosts).Clean(0xc0000d9ac8)
==> default: /home/runner/go/pkg/mod/github.com/goodhosts/[email protected]/hosts.go:130 +0x40
==> default: github.com/goodhosts/cli/cmd.remove(0xc00001ea00, 0x3, 0x4)
==> default: /home/runner/work/cli/cli/cmd/remove.go:75 +0x7f3
==> default: github.com/urfave/cli/v2.(*Command).Run(0xc0000127e0, 0xc00001e840, 0x0, 0x0)
==> default: /home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/command.go:161 +0x4b9
==> default: github.com/urfave/cli/v2.(*App).RunContext(0xc000001200, 0x127d980, 0xc00001a080, 0xc000010050, 0x5, 0x5, 0x0, 0x0)
==> default: /home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/app.go:302 +0x790
==> default: github.com/urfave/cli/v2.(*App).Run(...)
==> default: /home/runner/go/pkg/mod/github.com/urfave/cli/[email protected]/app.go:211
==> default: main.main()
==> default: /home/runner/work/cli/cli/main.go:55 +0x48e
Seems the line with the issue is https://github.com/goodhosts/hostsfile/blob/master/hosts.go#L297
Metadata
Metadata
Assignees
Labels
No labels