summaryrefslogtreecommitdiffstats
path: root/src/dbi.c
diff options
context:
space:
mode:
authorOpenGnSys Support Team <soporte-og@soleta.eu>2020-10-07 11:10:36 +0200
committerOpenGnSys Support Team <soporte-og@soleta.eu>2020-10-07 11:17:00 +0200
commitfe1ce97c50e575201fe47d7587251e228edf8fdf (patch)
tree4656eeb2fe23e2ef1a148af1303cae329c449078 /src/dbi.c
parent3cea4bb763165d119a329a1c7f2c767857cdb384 (diff)
#988 remove legacy configuration
Use og_server_cfg everywhere. Convert port to string to make it easy for the dbi API since it expects a string. Remove legacy example configuration file.
Diffstat (limited to 'src/dbi.c')
-rw-r--r--src/dbi.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/dbi.c b/src/dbi.c
index 3c4ae51..968b00e 100644
--- a/src/dbi.c
+++ b/src/dbi.c
@@ -30,11 +30,11 @@ struct og_dbi *og_dbi_open(struct og_dbi_config *config)
return NULL;
}
- dbi_conn_set_option(dbi->conn, "host", config->host);
+ dbi_conn_set_option(dbi->conn, "host", config->ip);
dbi_conn_set_option(dbi->conn, "port", config->port);
dbi_conn_set_option(dbi->conn, "username", config->user);
- dbi_conn_set_option(dbi->conn, "password", config->passwd);
- dbi_conn_set_option(dbi->conn, "dbname", config->database);
+ dbi_conn_set_option(dbi->conn, "password", config->pass);
+ dbi_conn_set_option(dbi->conn, "dbname", config->name);
dbi_conn_set_option(dbi->conn, "encoding", "UTF-8");
if (dbi_conn_connect(dbi->conn) < 0) {