postgresql_db: check connection status
During startup, check for a successfull connection to the db
committer: Markus Bröker <mbroeker@largo.homelinux.org>
--- a/db_bridge/postgresql_db.cpp
+++ b/db_bridge/postgresql_db.cpp
@@ -42,6 +42,10 @@
return false;
}
+ if (PQstatus(conn) != CONNECTION_OK) {
+ return false;
+ }
+
return true;
}