1
0
mirror of https://github.com/golang/go synced 2024-11-24 05:00:18 -07:00

net/rpc/jsonrpc: use strings.Builder

Change-Id: I251f734adbaf83aa03e3f4f37add4e116f5af093
Reviewed-on: https://go-review.googlesource.com/c/go/+/428271
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Ian Lance Taylor <iant@google.com>
This commit is contained in:
cuiweixie 2022-09-04 18:39:48 +08:00 committed by Gopher Robot
parent 2b8f214094
commit bfadd78986

View File

@ -5,7 +5,6 @@
package jsonrpc
import (
"bytes"
"encoding/json"
"errors"
"fmt"
@ -262,7 +261,7 @@ func TestMalformedOutput(t *testing.T) {
}
func TestServerErrorHasNullResult(t *testing.T) {
var out bytes.Buffer
var out strings.Builder
sc := NewServerCodec(struct {
io.Reader
io.Writer