From abd287159e7eb7d20ee46c03d1a8cb9a645735e4 Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Fri, 28 Feb 2020 08:53:29 -0800 Subject: [PATCH] tun: remove unused isUp method Signed-off-by: Brad Fitzpatrick --- tun/tun_linux.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/tun/tun_linux.go b/tun/tun_linux.go index 7ab0623..17b8822 100644 --- a/tun/tun_linux.go +++ b/tun/tun_linux.go @@ -12,7 +12,6 @@ import ( "bytes" "errors" "fmt" - "net" "os" "sync" "syscall" @@ -164,11 +163,6 @@ func (tun *NativeTun) routineNetlinkListener() { } } -func (tun *NativeTun) isUp() (bool, error) { - inter, err := net.InterfaceByName(tun.name) - return inter.Flags&net.FlagUp != 0, err -} - func getIFIndex(name string) (int32, error) { fd, err := unix.Socket( unix.AF_INET,