aboutsummaryrefslogtreecommitdiff
path: root/sqlite3.go
diff options
context:
space:
mode:
Diffstat (limited to 'sqlite3.go')
-rw-r--r--sqlite3.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/sqlite3.go b/sqlite3.go
index 6cd5c0e..c7eaf4d 100644
--- a/sqlite3.go
+++ b/sqlite3.go
@@ -627,11 +627,11 @@ func (d *SQLiteDriver) Open(dsn string) (driver.Conn, error) {
// Close the connection.
func (c *SQLiteConn) Close() error {
- deleteHandles(c)
rv := C.sqlite3_close_v2(c.db)
if rv != C.SQLITE_OK {
return c.lastError()
}
+ deleteHandles(c)
c.db = nil
runtime.SetFinalizer(c, nil)
return nil