dovecot-2.0: mysql, sqlite: Update db state to disconnected on d...
dovecot at dovecot.org
dovecot at dovecot.org
Fri May 28 13:47:47 EEST 2010
details: http://hg.dovecot.org/dovecot-2.0/rev/8c521fd311c6
changeset: 11406:8c521fd311c6
user: Timo Sirainen <tss at iki.fi>
date: Fri May 28 11:46:55 2010 +0100
description:
mysql, sqlite: Update db state to disconnected on deinit.
diffstat:
src/lib-sql/driver-mysql.c | 2 ++
src/lib-sql/driver-sqlite.c | 2 ++
2 files changed, 4 insertions(+), 0 deletions(-)
diffs (24 lines):
diff -r bd0088e294ec -r 8c521fd311c6 src/lib-sql/driver-mysql.c
--- a/src/lib-sql/driver-mysql.c Fri May 28 11:22:04 2010 +0100
+++ b/src/lib-sql/driver-mysql.c Fri May 28 11:46:55 2010 +0100
@@ -203,6 +203,8 @@
{
struct mysql_db *db = (struct mysql_db *)_db;
+ sql_db_set_state(&db->api, SQL_DB_STATE_DISCONNECTED);
+
mysql_close(db->mysql);
array_free(&_db->module_contexts);
pool_unref(&db->pool);
diff -r bd0088e294ec -r 8c521fd311c6 src/lib-sql/driver-sqlite.c
--- a/src/lib-sql/driver-sqlite.c Fri May 28 11:22:04 2010 +0100
+++ b/src/lib-sql/driver-sqlite.c Fri May 28 11:46:55 2010 +0100
@@ -88,6 +88,8 @@
{
struct sqlite_db *db = (struct sqlite_db *)_db;
+ sql_db_set_state(&db->api, SQL_DB_STATE_DISCONNECTED);
+
sqlite3_close(db->sqlite);
array_free(&_db->module_contexts);
pool_unref(&db->pool);
More information about the dovecot-cvs
mailing list