]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
mysql: When using multiple hosts, it never connected to more than the first one.
authorTimo Sirainen <tss@iki.fi>
Wed, 17 Nov 2010 16:55:56 +0000 (16:55 +0000)
committerTimo Sirainen <tss@iki.fi>
Wed, 17 Nov 2010 16:55:56 +0000 (16:55 +0000)
src/lib-sql/driver-mysql.c

index 1f5060643973c86b16d8638e14f03f5e591e6f15..f8b9df7d70e2a197b05d7b743cdce65f46a39ce9 100644 (file)
@@ -61,6 +61,8 @@ static int driver_mysql_connect(struct sql_db *_db)
 
        i_assert(db->api.state == SQL_DB_STATE_DISCONNECTED);
 
+       sql_db_set_state(&db->api, SQL_DB_STATE_CONNECTING);
+
        if (*db->host == '/') {
                unix_socket = db->host;
                host = NULL;