Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Merge pull request #246 from kamichidu/fix-leaking
refs #245 add test to check connection leaking
- Loading branch information
Showing
with
97 additions
and 0 deletions.
- +1 −0 store.go
- +36 −0 tests/common_test.go
- +1 −0 tests/resultset_test.go
- +59 −0 tests/store_test.go
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -439,6 +439,7 @@ func (s *Store) Reload(schema Schema, record Record) error { | ||
if err != nil { | ||
return err | ||
} | ||
defer rows.Close() | ||
|
||
rs := NewResultSet(rows, false, nil, columns...) | ||
if !rs.Next() { | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters