sql-pool.c revision 3ccab0bac68040f179a7de45c516cec258e28fdb
/* Copyright (c) 2004-2008 Dovecot authors, see the included COPYING file */
#include "lib.h"
#include "array.h"
#include "hash.h"
#include "sql-api-private.h"
#include "sql-pool.h"
#define SQL_POOL_CONTEXT(obj) \
struct sql_pool_context {
union sql_db_module_context module_ctx;
int refcount;
char *key;
};
struct sql_pool {
struct hash_table *dbs;
unsigned int unused_count, max_unused_connections;
};
{
struct sql_pool_context *head_ctx;
return;
else {
}
}
{
else {
}
else {
}
}
{
struct sql_pool_context *ctx;
}
}
const char *db_driver, const char *connect_string)
{
struct sql_pool_context *ctx;
char *key;
}
} else {
}
return db;
}
{
return pool;
}
{
}