aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/pprof
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2020-02-24 18:35:17 -0800
committerIan Lance Taylor <iant@golang.org>2020-02-26 04:38:19 +0000
commit6052838bc325049505aba9c3b87256161f9e05e8 (patch)
tree5d566da7ff0796abd2eb08c168ac2547948fac67 /src/runtime/pprof
parentc46ffdd2eca339918ed30b6ba9d4715ba769d35d (diff)
downloadgo-6052838bc325049505aba9c3b87256161f9e05e8.tar.gz
go-6052838bc325049505aba9c3b87256161f9e05e8.zip
all: avoid string(i) where i has type int
Instead use string(r) where r has type rune. This is in preparation for a vet warning for string(i). Updates #32479 Change-Id: Ic205269bba1bd41723950219ecfb67ce17a7aa79 Reviewed-on: https://go-review.googlesource.com/c/go/+/220844 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Akhil Indurti <aindurti@gmail.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Toshihiro Shiino <shiino.toshihiro@gmail.com>
Diffstat (limited to 'src/runtime/pprof')
-rw-r--r--src/runtime/pprof/internal/profile/proto.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/pprof/internal/profile/proto.go b/src/runtime/pprof/internal/profile/proto.go
index 11d7f9ff9b..294acfeb92 100644
--- a/src/runtime/pprof/internal/profile/proto.go
+++ b/src/runtime/pprof/internal/profile/proto.go
@@ -232,7 +232,7 @@ func decodeField(b *buffer, data []byte) ([]byte, error) {
b.u64 = uint64(le32(data[:4]))
data = data[4:]
default:
- return nil, errors.New("unknown type: " + string(b.typ))
+ return nil, errors.New("unknown type: " + string(rune(b.typ)))
}
return data, nil