res_config_pgsql: Show error message in reload if not connected.

Change-Id: I9290115a1aaadb589eb1d02eaeb502eec01b31fa
This commit is contained in:
Rodrigo Ramírez Norambuena
2016-02-09 23:13:07 -03:00
parent 68643f83cd
commit fd668670b5

View File

@@ -1351,6 +1351,9 @@ static int parse_config(int is_reload)
config = ast_config_load(RES_CONFIG_PGSQL_CONF, config_flags);
if (config == CONFIG_STATUS_FILEUNCHANGED) {
if (is_reload && pgsqlConn && PQstatus(pgsqlConn) != CONNECTION_OK) {
ast_log(LOG_WARNING, "PostgreSQL RealTime: Not connected\n");
}
return 0;
}