[Asterisk-code-review] res config pgsql: Make 'require' return consistent with othe... (asterisk[14])

Anonymous Coward asteriskteam at digium.com
Wed Mar 1 10:56:45 CST 2017


Anonymous Coward #1000019 has submitted this change and it was merged. ( https://gerrit.asterisk.org/5111 )

Change subject: res_config_pgsql: Make 'require' return consistent with other backends
......................................................................


res_config_pgsql: Make 'require' return consistent with other backends

res_config_pgsql should match the behavior of other realtime backend
drivers so that queue_log can disable adaptive logging.

ASTERISK-25628 #close
Reported by: Dmitry Wagin

Change-Id: Ic1fb1600c7ce10fdfb1bcdc43c5576b7e0014372
---
M res/res_config_pgsql.c
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  George Joseph: Looks good to me, approved
  Anonymous Coward #1000019: Verified
  Joshua Colp: Looks good to me, but someone else must approve



diff --git a/res/res_config_pgsql.c b/res/res_config_pgsql.c
index 3c91f9d..def998c 100644
--- a/res/res_config_pgsql.c
+++ b/res/res_config_pgsql.c
@@ -1286,6 +1286,7 @@
 		if (!column) {
 			if (requirements == RQ_WARN) {
 				ast_log(LOG_WARNING, "Table %s requires a column '%s' of size '%d', but no such column exists.\n", tablename, elm, size);
+				res = -1;
 			} else {
 				struct ast_str *sql = ast_str_create(100);
 				char fieldtype[15];

-- 
To view, visit https://gerrit.asterisk.org/5111
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ic1fb1600c7ce10fdfb1bcdc43c5576b7e0014372
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 14
Gerrit-Owner: Sean Bright <sean.bright at gmail.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>



More information about the asterisk-code-review mailing list