summaryrefslogtreecommitdiff
path: root/src/utils/reload.cpp
diff options
context:
space:
mode:
authorlouiz’ <louiz@louiz.org>2017-06-14 00:04:19 +0200
committerlouiz’ <louiz@louiz.org>2017-06-14 00:19:15 +0200
commit8d1d822edf72e2bf426a1512fb2e19ef65e97b8c (patch)
tree22b91a176254edfdfa0526bbb477ff7126951802 /src/utils/reload.cpp
parent9defd0ccb75b1905c308ed0437e5ccd479e3a7b8 (diff)
downloadbiboumi-8d1d822edf72e2bf426a1512fb2e19ef65e97b8c.tar.gz
biboumi-8d1d822edf72e2bf426a1512fb2e19ef65e97b8c.tar.bz2
biboumi-8d1d822edf72e2bf426a1512fb2e19ef65e97b8c.tar.xz
biboumi-8d1d822edf72e2bf426a1512fb2e19ef65e97b8c.zip
Explicitely close the Database before re-opening it
Diffstat (limited to 'src/utils/reload.cpp')
-rw-r--r--src/utils/reload.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/utils/reload.cpp b/src/utils/reload.cpp
index fdca9bc..807a9ab 100644
--- a/src/utils/reload.cpp
+++ b/src/utils/reload.cpp
@@ -11,6 +11,7 @@ void open_database()
#ifdef USE_DATABASE
const auto db_filename = Config::get("db_name", xdg_data_path("biboumi.sqlite"));
log_info("Opening database: ", db_filename);
+ Database::close();
Database::open(db_filename);
log_info("database successfully opened.");
#endif