summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/dbi.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/dbi.c b/src/dbi.c
index 234e91e..aaf6c8b 100644
--- a/src/dbi.c
+++ b/src/dbi.c
@@ -39,6 +39,7 @@ struct og_dbi *og_dbi_open(struct og_dbi_config *config)
dbi_conn_set_option(dbi->conn, "encoding", "UTF-8");
if (dbi_conn_connect(dbi->conn) < 0) {
+ dbi_shutdown_r(dbi->inst);
free(dbi);
return NULL;
}