summaryrefslogtreecommitdiffstats
path: root/src/libs/zbxdbhigh/db.c
diff options
context:
space:
mode:
authorsasha <sasha@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2008-03-06 12:56:44 +0000
committersasha <sasha@97f52cf1-0a1b-0410-bd0e-c28be96e8082>2008-03-06 12:56:44 +0000
commitbc87e8b5844d32a4b6367ca7ecc6aec56a1adf28 (patch)
treed909561e095c41f10d984147442a3d49071a8ae2 /src/libs/zbxdbhigh/db.c
parent4fadc291f8754315252c8c05af222eb92520555e (diff)
downloadzabbix-bc87e8b5844d32a4b6367ca7ecc6aec56a1adf28.tar.gz
zabbix-bc87e8b5844d32a4b6367ca7ecc6aec56a1adf28.tar.xz
zabbix-bc87e8b5844d32a4b6367ca7ecc6aec56a1adf28.zip
- [DEV-131] First boot - database creation (sqlite3)
git-svn-id: svn://svn.zabbix.com/trunk@5455 97f52cf1-0a1b-0410-bd0e-c28be96e8082
Diffstat (limited to 'src/libs/zbxdbhigh/db.c')
-rw-r--r--src/libs/zbxdbhigh/db.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/src/libs/zbxdbhigh/db.c b/src/libs/zbxdbhigh/db.c
index 238668ae..998764ad 100644
--- a/src/libs/zbxdbhigh/db.c
+++ b/src/libs/zbxdbhigh/db.c
@@ -57,7 +57,6 @@ void DBclose(void)
zbx_db_close();
}
-
/*
* Connect to the database.
* If fails, program terminates.
@@ -91,6 +90,26 @@ void DBconnect(int flag)
/******************************************************************************
* *
+ * Function: DBinit *
+ * *
+ * Purpose: *
+ * *
+ * Parameters: *
+ * *
+ * Return value: *
+ * *
+ * Author: Alksander Vladishev *
+ * *
+ * Comments: *
+ * *
+ ******************************************************************************/
+void DBinit()
+{
+ zbx_db_init(CONFIG_DBHOST, CONFIG_DBUSER, CONFIG_DBPASSWORD, CONFIG_DBNAME, CONFIG_DBSOCKET, CONFIG_DBPORT);
+}
+
+/******************************************************************************
+ * *
* Function: DBping *
* *
* Purpose: Check if database is down *
@@ -2057,3 +2076,4 @@ int DBproxy_add_history_str(zbx_uint64_t itemid, char *value, int clock)
return SUCCEED;
}
+