[asterisk-bugs] [JIRA] (ASTERISK-26173) func_cdr: CDR function does not permit empty values to be assigned

Joshua Colp (JIRA) noreply at issues.asterisk.org
Fri May 5 06:19:58 CDT 2017


     [ https://issues.asterisk.org/jira/browse/ASTERISK-26173?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Joshua Colp reassigned ASTERISK-26173:
--------------------------------------

    Assignee: Joshua Colp

> func_cdr: CDR function does not permit empty values to be assigned
> ------------------------------------------------------------------
>
>                 Key: ASTERISK-26173
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-26173
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Functions/func_cdr
>    Affects Versions: 13.7.0, 13.9.1
>         Environment: Will affect all operating systems and platforms (see description).
>            Reporter: gkloepfer
>            Assignee: Joshua Colp
>            Severity: Minor
>
> As of at least 13.7.0 (probably affects earlier releases), function CDR (func_cdr.c) does not allow empty values to be assigned to any CDR variables.  This was permitted in earlier Asterisk releases (11.x, for example, allowed this behavior).  Attempting to assign an empty value from the dialplan, as in:
> {noformat}
> same => n,Set(CDR(final_ganyid)=${myvariable})
> {noformat}
> will fail if the variable $\{myvariable} is empty (or if the assignment is purposely blank) with a message such as:
> {noformat}
> [Jul  5 10:57:20] WARNING[2875]: func_cdr.c:352 cdr_write_callback: CDR requires a value (CDR(variable)=value)
> {noformat}
> In func_cdr.c (cdr_write_callback) this is due to the following code:
> {code:title=func_cdr.c}
>         if (ast_strlen_zero(payload->value)) {
>                 ast_log(AST_LOG_WARNING, "%s requires a value (%s(variable)=value)\n)",
>                         payload->cmd, payload->cmd);
>                 return;
>         }
> {code}



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list