[asterisk-bugs] [JIRA] (ASTERISK-29495) Return integer instead of float if response is a whole number

Joshua C. Colp (JIRA) noreply at issues.asterisk.org
Mon Jun 28 09:30:33 CDT 2021


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

Joshua C. Colp updated ASTERISK-29495:
--------------------------------------

    Assignee: N A

> Return integer instead of float if response is a whole number
> -------------------------------------------------------------
>
>                 Key: ASTERISK-29495
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-29495
>             Project: Asterisk
>          Issue Type: Improvement
>      Security Level: None
>          Components: Functions/func_math
>    Affects Versions: 18.5.0
>            Reporter: N A
>            Assignee: N A
>
> While support for floats is good, a minor caveat with these is if all arguments are integers, the answer will be an whole number and an integer response is likely expected. Currently these always returns a float for MAX, MIN, and ABS. This patch causes the response to be cast to an integer before being printed into the buffer if the answer is a whole number.



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



More information about the asterisk-bugs mailing list