src/client/pkg/pbutil/pbutil.go
func (r *readWriter) Write(val proto.Message) (int64, error) {
	bytes, err := proto.Marshal(val)
	if err != nil {
		return 0, err
	}
	return r.WriteBytes(bytes)
}
func (r *readWriter) Write(val proto.Message) (int64, error) {
	bytes, err := proto.Marshal(val)
	if err != nil {
		return 0, err
	}
	return r.WriteBytes(bytes)
}
// Write writes val to r.