Skip to content

Commit 5ed9523

Browse files
mvdanrsc
authored andcommitted
runtime/pprof: actually use tag parameter
It's only ever called with the value it was using, but the code was counterintuitive. Use the parameter instead, like the other funcs near it. Found by github.com/mvdan/unparam. Change-Id: I45855e11d749380b9b2a28e6dd1d5dedf119a19b Reviewed-on: https://go-review.googlesource.com/37893 Reviewed-by: Russ Cox <[email protected]> Run-TryBot: Russ Cox <[email protected]> TryBot-Result: Gobot Gobot <[email protected]>
1 parent 143fd8e commit 5ed9523

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/pprof/proto.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ func (b *profileBuilder) pbMapping(tag int, id, base, limit, offset uint64, file
178178
b.pb.int64Opt(tagMapping_Filename, b.stringIndex(file))
179179
// TODO: Set any of HasInlineFrames, HasFunctions, HasFilenames, HasLineNumbers?
180180
// It seems like they should all be true, but they've never been set.
181-
b.pb.endMessage(tagProfile_Mapping, start)
181+
b.pb.endMessage(tag, start)
182182
}
183183

184184
// locForPC returns the location ID for addr.

0 commit comments

Comments
 (0)