Merge pull request #745 from un000/master
Properly close a pool on "not lazy" connect
This commit is contained in:
+1
-1
@@ -189,7 +189,7 @@ func ConnectConfig(ctx context.Context, config *Config) (*Pool, error) {
|
||||
// Initially establish one connection
|
||||
res, err := p.p.Acquire(ctx)
|
||||
if err != nil {
|
||||
p.p.Close()
|
||||
p.Close()
|
||||
return nil, err
|
||||
}
|
||||
res.Release()
|
||||
|
||||
Reference in New Issue
Block a user