Re: [OpenSIPS-Devel] [opensips] mod_fix: new helper fixup function that returns string and/or int value from a gparam_t (7870f22)
Personally, I consider that *fixup_get_isvalue* would have a lot more value if it did had the option to do conversions internally, thus masking the whole flag pvar logic behind it. It should have a prototype such as: int fixup_get_isvalue(struct sip_msg* msg, gparam_p gp, int_str *out, enum conv); where conv could be { CONVERT_NONE, CONVERT_TO_INT, CONVERT_TO_STR } --- Reply to this email directly or view it on GitHub: https://github.com/OpenSIPS/opensips/commit/7870f22613f2c6873177b615326e81d217e141a9#commitcomment-5509080___ Devel mailing list Devel@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/devel
Re: [OpenSIPS-Devel] [opensips] mod_fix: new helper fixup function that returns string and/or int value from a gparam_t (7870f22)
The purpose of the fixup function is to get both int and str (if possible). Since in_str is a union, that would not work. However, doing the conversion from str to int internally is a good idea. Thanks for reviewing the commit! --- Reply to this email directly or view it on GitHub: https://github.com/OpenSIPS/opensips/commit/7870f22613f2c6873177b615326e81d217e141a9#commitcomment-5511601___ Devel mailing list Devel@lists.opensips.org http://lists.opensips.org/cgi-bin/mailman/listinfo/devel