internal/trace/internal/testgen: fix missing stacks nframes arg

Change-Id: I6a6a6964c9c1322bfe289394d5d3937d1f7097bb
Reviewed-on: https://go-review.googlesource.com/c/go/+/694616
Reviewed-by: Michael Knyszek <mknyszek@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: David Chase <drchase@google.com>
Auto-Submit: Michael Knyszek <mknyszek@google.com>
This commit is contained in:
Felix Geisendörfer 2025-06-22 15:29:34 +02:00 committed by Gopher Robot
parent 889ab74169
commit 750789fab7

View file

@ -295,7 +295,7 @@ func (g *Generation) writeEventsTo(tw *raw.TextWriter) {
b.RawEvent(tracev2.EvStacks, nil)
for stk, id := range g.stacks {
stk := stk.stk[:stk.len]
args := []uint64{id}
args := []uint64{id, uint64(len(stk))}
for _, f := range stk {
args = append(args, f.PC, g.String(f.Func), g.String(f.File), f.Line)
}