From 71fa60fc5d60b2580de9c70e9f5df4ec08584974 Mon Sep 17 00:00:00 2001 From: HeyJavaBean Date: Wed, 11 Dec 2024 17:56:37 +0800 Subject: [PATCH] fix: fix by comment --- protocol/thrift/apache/adaptor/struct_codec.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/protocol/thrift/apache/adaptor/struct_codec.go b/protocol/thrift/apache/adaptor/struct_codec.go index 4d4dc48..aff68be 100644 --- a/protocol/thrift/apache/adaptor/struct_codec.go +++ b/protocol/thrift/apache/adaptor/struct_codec.go @@ -84,7 +84,7 @@ func (c *oldFastCodec) BLength() int { func (c *oldFastCodec) FastWriteNocopy(buf []byte, bw thrift.NocopyWriter) int { method := c.method - out := method.Call([]reflect.Value{reflect.ValueOf(buf), reflect.New(method.Type().In(1)).Elem()}) + out := method.Call([]reflect.Value{reflect.ValueOf(buf), reflect.NewAt(method.Type().In(1), nil)}) return out[0].Interface().(int) }