From b52fab1a32ec7072cdee0d66e86657fe970b10a9 Mon Sep 17 00:00:00 2001 From: "Jason A. Donenfeld" Date: Mon, 3 Jun 2019 12:14:39 +0200 Subject: tunnel: fix formatting Signed-off-by: Jason A. Donenfeld --- Makefile | 6 +++++- tunnel/firewall/helpers.go | 4 ++-- tunnel/ifaceconfig.go | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 9bc56260..eb50bc37 100644 --- a/Makefile +++ b/Makefile @@ -41,6 +41,10 @@ x86/wireguard.exe: export GOARCH := 386 x86/wireguard.exe: resources_386.syso $(SOURCE_FILES) go build $(GOFLAGS) -o $@ +fmt: export CC := i686-w64-mingw32-gcc +fmt: + go fmt ./... + deploy: amd64/wireguard.exe -ssh $(DEPLOYMENT_HOST) -- 'taskkill /im wireguard.exe /f' scp $< $(DEPLOYMENT_HOST):$(DEPLOYMENT_PATH) @@ -48,4 +52,4 @@ deploy: amd64/wireguard.exe clean: rm -rf *.syso ui/icon/*.ico x86/ amd64/ .deps -.PHONY: deploy clean all +.PHONY: deploy clean fmt all diff --git a/tunnel/firewall/helpers.go b/tunnel/firewall/helpers.go index 79ab0d82..1c60558b 100644 --- a/tunnel/firewall/helpers.go +++ b/tunnel/firewall/helpers.go @@ -6,13 +6,13 @@ package firewall import ( + "crypto/rand" "fmt" "io" "os" "runtime" "syscall" "unsafe" - "crypto/rand" "golang.org/x/sys/windows" ) @@ -148,4 +148,4 @@ func randGUID() (windows.GUID, error) { return guid, io.ErrShortBuffer } return guid, nil -} \ No newline at end of file +} diff --git a/tunnel/ifaceconfig.go b/tunnel/ifaceconfig.go index 3954441b..a64a469b 100644 --- a/tunnel/ifaceconfig.go +++ b/tunnel/ifaceconfig.go @@ -239,4 +239,4 @@ func waitForFamilies(tun *tun.NativeTun) { luid := winipcfg.LUID(tun.LUID()) f(luid, windows.AF_INET, 100) f(luid, windows.AF_INET6, 3) -} \ No newline at end of file +} -- cgit v1.2.3-59-g8ed1b