Module: DB_POSTGRES :: the PostgreSQL driver for Kamailio. More...
#include "pg_con.h"
#include "../../mem/mem.h"
#include "../../dprint.h"
#include "../../ut.h"
#include <string.h>
#include <time.h>

Go to the source code of this file.
Functions | |
| void | db_postgres_free_connection (struct pool_con *con) |
| Close the connection and release memory. | |
| struct pg_con * | db_postgres_new_connection (struct db_id *id) |
| Create a new connection. | |
Module: DB_POSTGRES :: the PostgreSQL driver for Kamailio.
Definition in file pg_con.c.
| void db_postgres_free_connection | ( | struct pool_con * | con | ) |
Close the connection and release memory.
| con | connection |
Definition at line 108 of file pg_con.c.
References pg_con::con, free_db_id(), pg_con::id, LM_DBG, pkg_free, and pg_con::res.
Referenced by db_postgres_close().
Create a new connection.
Create a new connection structure in private memory, open the PostgreSQL connection and set reference count to 1
| id | database id |
Definition at line 46 of file pg_con.c.
References pg_con::con, pg_con::connected, db_id::database, db_id::host, pg_con::id, int2str(), LM_DBG, LM_ERR, NULL, db_id::password, pkg_free, pkg_malloc, db_id::port, pg_con::ref, pg_con::timestamp, db_id::username, and ZSW.
Referenced by db_postgres_init().
1.5.6