From c21b8a3d7e5925f0682c137d474ca922162dd1b3 Mon Sep 17 00:00:00 2001 From: Steffen Vogel Date: Tue, 15 Jun 2021 20:50:59 +0200 Subject: [PATCH] remove unused function --- iface/iface.go | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/iface/iface.go b/iface/iface.go index fe86eb238a3..cb51e9ffdd3 100644 --- a/iface/iface.go +++ b/iface/iface.go @@ -1,14 +1,15 @@ package iface import ( + "net" + "time" + log "github.com/sirupsen/logrus" "golang.zx2c4.com/wireguard/conn" "golang.zx2c4.com/wireguard/device" "golang.zx2c4.com/wireguard/tun" "golang.zx2c4.com/wireguard/wgctrl" "golang.zx2c4.com/wireguard/wgctrl/wgtypes" - "net" - "time" ) const ( @@ -148,12 +149,6 @@ func UpdateListenPort(iface string, newPort int) error { return nil } -func ifname(n string) []byte { - b := make([]byte, 16) - copy(b, []byte(n+"\x00")) - return b -} - // UpdatePeer updates existing Wireguard Peer or creates a new one if doesn't exist // Endpoint is optional func UpdatePeer(iface string, peerKey string, allowedIps string, keepAlive time.Duration, endpoint string) error {