You've already forked getidev
Compare commits
2 Commits
5f55a75aed
...
1181a47282
Author | SHA1 | Date | |
---|---|---|---|
1181a47282
|
|||
c7d8002cd2
|
7
main.go
7
main.go
@ -8,8 +8,6 @@ import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
var version string
|
||||
|
||||
func main() {
|
||||
ips := os.Args[1:]
|
||||
switch {
|
||||
@ -34,7 +32,10 @@ func main() {
|
||||
|
||||
for _, addr := range addrs {
|
||||
if strings.Split(addr.String(), "/")[0] == ip {
|
||||
fmt.Fprintln(os.Stdout, iface.Name)
|
||||
_, err = fmt.Fprintln(os.Stdout, iface.Name)
|
||||
if err != nil {
|
||||
log.Fatal(err.Error())
|
||||
}
|
||||
return
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user