Skip to content

Commit 0c022a7

Browse files
authored
fix pointer receiver
1 parent 53e5166 commit 0c022a7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/debug/api.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ func (*HandlerT) WriteMemProfile(file string) error {
191191

192192
// Stacks returns a printed representation of the stacks of all goroutines.
193193
func (*HandlerT) Stacks() string {
194-
var buf bytes.Buffer
194+
buf := new(bytes.Buffer)
195195
pprof.Lookup("goroutine").WriteTo(buf, 2)
196196
return buf.String()
197197
}

0 commit comments

Comments
 (0)