Hello,

On 8/2/10 1:23 PM, Chandrakant Solanki wrote:
Hi

Is kamailio support floating point operation like..

num1 = 1
num2 = 3

num3 = num1 / num2 i. e. 0.33 = 1 / 3

Is it possible...?? If yes, How ??

no, it is not possible in current version. The cfg variables can hold string and integers. There is an extension called XAVP which can hold other types, but is not enabled by default (you have to recompile with -DWITH_XAVP) and even enabled you cannot operate floats on it from config file.

An workaround could be usage of embedded language (exec, perl for <=3.0, lua, python for later) to do the operations and store the result as string in a cfg variable.

Cheers,
Daniel


Any Idea??

--
Regards,

Chandrakant Solanki
_______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
http://www.asipto.com/