diff options
author | Jakob Unterwurzacher | 2016-04-10 21:29:42 +0200 |
---|---|---|
committer | Jakob Unterwurzacher | 2016-04-10 21:31:15 +0200 |
commit | bd5405189eb27d463e25c43691b19dbdf174d3a8 (patch) | |
tree | a78d909a5fac9b3c642ea5c1a715a08bffa54965 /main.go | |
parent | bd1f17ca9f210b318e28d7ed233698b950d564b8 (diff) |
Fix "go tool vet -shadow=true" warnings
Among those one real bug.
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -224,7 +224,8 @@ func main() { // "-cpuprofile" if args.cpuprofile != "" { toggledlog.Info.Printf("Writing CPU profile to %s", args.cpuprofile) - f, err := os.Create(args.cpuprofile) + var f *os.File + f, err = os.Create(args.cpuprofile) if err != nil { fmt.Println(err) os.Exit(ERREXIT_INIT) @@ -235,7 +236,8 @@ func main() { // "-memprofile" if args.memprofile != "" { toggledlog.Info.Printf("Writing mem profile to %s", args.memprofile) - f, err := os.Create(args.memprofile) + var f *os.File + f, err = os.Create(args.memprofile) if err != nil { fmt.Println(err) os.Exit(ERREXIT_INIT) |