move all the buffer references to util/buf

This commit is contained in:
Asim Aslam
2019-07-28 19:33:24 +01:00
parent f2669e7b1e
commit 1db98ee0f0
9 changed files with 25 additions and 64 deletions

View File

@@ -11,6 +11,7 @@ import (
"github.com/micro/go-micro/codec"
"github.com/micro/go-micro/metadata"
"github.com/micro/go-micro/registry"
"github.com/micro/go-micro/util/buf"
)
const (
@@ -210,7 +211,7 @@ func (s *rpcServer) createSubHandler(sb *subscriber, opts Options) broker.Handle
req = req.Elem()
}
b := &buffer{bytes.NewBuffer(msg.Body)}
b := buf.New(bytes.NewBuffer(msg.Body))
co := cf(b)
defer co.Close()