jameshartig commented on code in PR #1895:
URL: 
https://github.com/apache/cassandra-gocql-driver/pull/1895#discussion_r2161788055


##########
control.go:
##########
@@ -322,7 +322,11 @@ func (c *controlConn) setupConn(conn *Conn, sessionInit 
bool) error {
        iter := conn.querySystemLocal(context.TODO())
        host, err := c.session.hostInfoFromIter(iter, conn.host.connectAddress, 
conn.r.RemoteAddr().(*net.TCPAddr).Port)
        if err != nil {
-               return err
+               iter.Close()

Review Comment:
   This was mostly to just cleanup the iterator. We should probably return the 
error from `hostInfoFromIter`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to