diff options
| author | cui fliter <imcusg@gmail.com> | 2024-03-07 11:16:17 +0800 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2024-03-07 20:46:32 +0000 |
| commit | 8d3703ed77af699db9d28ace26081b84dc3706e7 (patch) | |
| tree | 46cedc5f91315f761f77e2531927dd115a52e356 /src/net/http | |
| parent | 7101fd1e97c11db3af95b1d3ac6abaabd30d8945 (diff) | |
| download | go-8d3703ed77af699db9d28ace26081b84dc3706e7.tar.xz | |
all: remove redundant string conversions when formatting []byte with %s
Change-Id: I1285ee047fd465f48028186ae04d4de60cc9969e
Reviewed-on: https://go-review.googlesource.com/c/go/+/569715
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: shuang cui <imcusg@gmail.com>
Reviewed-by: Damien Neil <dneil@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Ian Lance Taylor <iant@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Diffstat (limited to 'src/net/http')
| -rw-r--r-- | src/net/http/cgi/host.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/net/http/cgi/host.go b/src/net/http/cgi/host.go index ef222ab73a..c03fabb807 100644 --- a/src/net/http/cgi/host.go +++ b/src/net/http/cgi/host.go @@ -277,7 +277,7 @@ func (h *Handler) ServeHTTP(rw http.ResponseWriter, req *http.Request) { headerLines++ header, val, ok := strings.Cut(string(line), ":") if !ok { - h.printf("cgi: bogus header line: %s", string(line)) + h.printf("cgi: bogus header line: %s", line) continue } if !httpguts.ValidHeaderFieldName(header) { |
