fix: delete one by one
This commit is contained in:
parent
678adb3e2f
commit
d679d620ca
@ -47,7 +47,8 @@ func (db *PreparedStmtDB) Close() {
|
|||||||
func (db *PreparedStmtDB) Reset() {
|
func (db *PreparedStmtDB) Reset() {
|
||||||
db.Mux.Lock()
|
db.Mux.Lock()
|
||||||
defer db.Mux.Unlock()
|
defer db.Mux.Unlock()
|
||||||
for _, stmt := range db.Stmts {
|
for query, stmt := range db.Stmts {
|
||||||
|
delete(db.Stmts, query)
|
||||||
go stmt.Close()
|
go stmt.Close()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user