Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
route params: Fix regression in 8761ce6
The patch assumed that variables with PV_VAL_INT|PV_TYPE_INT have symmetric values (e.g. 5 and "5"), whereas this is not always the case (e.g. 1 and "INVITE", returned by $rm) and would proceed to duplicate the output buffer as a int2str() buffer, for safety purposes. The fix is to avoid the duplication completely (i.e. do not overwrite "INVITE" with "1"), thanks to the route params array string buffers having a sufficiently large lifetime in order to be safely returned to the calling code asking for the route parameter. (cherry picked from commit 6b9e140)
- Loading branch information