summaryrefslogtreecommitdiffhomepage
path: root/main.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2018-05-14 15:58:40 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2018-05-14 16:01:58 +0200
commita62c770a99e830f220314d1bc779e8818d4ecc7f (patch)
treeeebd952c61954cf172bd3f3efe29e404dc3b4697 /main.go
parent09235d48d8a77b38f5c2834adbcfcb9c68a1491a (diff)
Ugly hack to suppress warning on backgrounded process
Diffstat (limited to 'main.go')
-rw-r--r--main.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/main.go b/main.go
index 6e876df..09ba39e 100644
--- a/main.go
+++ b/main.go
@@ -30,6 +30,10 @@ func printUsage() {
}
func warning() {
+ if os.Getenv(ENV_WG_PROCESS_FOREGROUND) == "1" {
+ return
+ }
+
shouldQuit := false
fmt.Fprintln(os.Stderr, "WARNING WARNING WARNING WARNING WARNING WARNING WARNING")