From 03d6c648ab785130a3e9c3e762090e8135a7671c Mon Sep 17 00:00:00 2001 From: v2ray Date: Wed, 4 May 2016 23:41:09 +0200 Subject: [PATCH] explictly invoke GC --- release/server/main.go | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/release/server/main.go b/release/server/main.go index 8ca1763a..d487eb76 100644 --- a/release/server/main.go +++ b/release/server/main.go @@ -5,6 +5,8 @@ import ( "fmt" "os" "path/filepath" + "runtime" + "time" "github.com/v2ray/v2ray-core" _ "github.com/v2ray/v2ray-core/app/router/rules" @@ -92,6 +94,7 @@ func main() { return } - finish := make(chan bool) - <-finish + for range time.Tick(time.Minute) { + runtime.GC() + } }