mirror of
https://github.com/redis/go-redis.git
synced 2025-07-29 17:41:15 +03:00
Close all connections.
This commit is contained in:
@ -113,7 +113,7 @@ func (c *baseClient) run(cmd Cmder) {
|
||||
}
|
||||
|
||||
if err := c.writeCmd(cn, cmd); err != nil {
|
||||
c.removeConn(cn)
|
||||
c.freeConn(cn, err)
|
||||
cmd.setErr(err)
|
||||
return
|
||||
}
|
||||
@ -173,10 +173,7 @@ func newClient(opt *Options, dial func() (net.Conn, error)) *Client {
|
||||
baseClient: &baseClient{
|
||||
opt: opt,
|
||||
|
||||
connPool: newConnPool(
|
||||
dial, opt.getPoolSize(),
|
||||
opt.IdleTimeout,
|
||||
),
|
||||
connPool: newConnPool(newConnFunc(dial), opt.getPoolSize(), opt.IdleTimeout),
|
||||
},
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user