From b366e69bd677db9f93d3c257db075e2590fbf215 Mon Sep 17 00:00:00 2001 From: Mikhail Filimonov <1549571+filimonov@users.noreply.github.com> Date: Tue, 5 Dec 2017 00:01:26 +0100 Subject: [PATCH] closing connection --- clickhouse_http.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/clickhouse_http.go b/clickhouse_http.go index 54249c5..edb90d5 100644 --- a/clickhouse_http.go +++ b/clickhouse_http.go @@ -232,8 +232,8 @@ func makeQuery2(cx context.Context, query, queryID, format string, interactive b return } - // connect to this socket - conn, err := net.Dial("tcp", getHost()) + conn, err := net.Dial("tcp", getHost()) // todo: ssl + defer conn.Close() // todo: keepalive if err != nil { qe := queryExecution{Err: err, PacketType: errPacket} queryExecutionChannel <- qe