[asterisk-commits] func cdr: Allow empty value for CDR dialplan function. (asterisk[13])

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon May 8 18:21:15 CDT 2017


Joshua Colp has submitted this change and it was merged. ( https://gerrit.asterisk.org/5586 )

Change subject: func_cdr: Allow empty value for CDR dialplan function.
......................................................................


func_cdr: Allow empty value for CDR dialplan function.

A regression was introduced in 12 where passing an empty value
to the CDR dialplan function was not longer allowed. This
change returns to the behavior of 11 where it is permitted.

ASTERISK-26173

Change-Id: I3f148203b54ec088007e29e30005a5de122e51c5
---
M funcs/func_cdr.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Kevin Harwell: Looks good to me, approved
  George Joseph: Looks good to me, but someone else must approve
  Joshua Colp: Approved for Submit



diff --git a/funcs/func_cdr.c b/funcs/func_cdr.c
index 12e6f3b..76d468b 100644
--- a/funcs/func_cdr.c
+++ b/funcs/func_cdr.c
@@ -379,7 +379,7 @@
 			payload->cmd, payload->cmd);
 		return;
 	}
-	if (ast_strlen_zero(payload->value)) {
+	if (!payload->value) {
 		ast_log(AST_LOG_WARNING, "%s requires a value (%s(variable)=value)\n)",
 			payload->cmd, payload->cmd);
 		return;

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I3f148203b54ec088007e29e30005a5de122e51c5
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-Owner: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>



More information about the asterisk-commits mailing list