Sfoglia il codice sorgente

Close the connection after checking the version

Oz N Tiram 8 anni fa
parent
commit
e3a87c7d6c
1 ha cambiato i file con 3 aggiunte e 0 eliminazioni
  1. 3 0
      pwman/data/drivers/sqlite.py

+ 3 - 0
pwman/data/drivers/sqlite.py

@@ -40,6 +40,9 @@ class SQLite(Database):
         cur = con.cursor()
         cur.execute("PRAGMA TABLE_INFO(DBVERSION)")
         row = cur.fetchone()
+        cur.close()
+        con.close()
+
         try:
             return row[-2]
         except TypeError: