Skip to content

Commit

Permalink
Resource leak issue fixed and added IDE files to .gitignore
Browse files Browse the repository at this point in the history
  • Loading branch information
qburst-basile committed Jan 31, 2023
1 parent 402f2b9 commit ed42b89
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
*.so
*.dylib

# IDE related
.idea

# Test binary, built with `go test -c`
*.test

Expand Down
3 changes: 2 additions & 1 deletion internal/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,15 @@ func (client *Client) Run(terminate chan<- error, routineUpdate chan<- []model.G
terminate <- fmt.Errorf("Failed to list go routines. Err: %s", err.Error())
return
}
defer resp.Body.Close()

goroutines, err := model.ParseStackFrame(resp.Body)
if err != nil {
log.Printf("Error while parsing stack: %s", err.Error())
} else {
routineUpdate <- goroutines
}

resp.Body.Close()
<-ticker.C
}
}

0 comments on commit ed42b89

Please sign in to comment.