Skip to content

Commit bc355c0

Browse files
committed
use one tcp protocol revision, remove multiple usage of ClientTCPProtocolVersion constant.
1 parent b662344 commit bc355c0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

conn_handshake.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ func (c *connect) handshake(auth Auth) error {
3737
{
3838
c.buffer.PutByte(proto.ClientHello)
3939
handshake := &proto.ClientHandshake{
40-
ProtocolVersion: ClientTCPProtocolVersion,
40+
ProtocolVersion: c.revision,
4141
ClientName: c.opt.ClientInfo.String(),
4242
ClientVersion: proto.Version{ClientVersionMajor, ClientVersionMinor, ClientVersionPatch}, //nolint:govet
4343
}

conn_send_query.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ func (c *connect) sendQuery(body string, o *QueryOptions) error {
2727
c.debugf("[send query] compression=%q %s", c.compression, body)
2828
c.buffer.PutByte(proto.ClientQuery)
2929
q := proto.Query{
30-
ClientTCPProtocolVersion: ClientTCPProtocolVersion,
30+
ClientTCPProtocolVersion: c.revision,
3131
ClientName: c.opt.ClientInfo.String(),
3232
ClientVersion: proto.Version{ClientVersionMajor, ClientVersionMinor, ClientVersionPatch}, //nolint:govet
3333
ID: o.queryID,

0 commit comments

Comments
 (0)