Hey @michelpelletier07,
Thanks for reporting this! Your patch seems to fix the problem and is in line with the rest of the code in the file regarding the `s.len` variables.
Would you like to create the PR yourself since you did the work? Otherwise, I can do it of course.
If you choose to do so, please make sure to keep in line with the contributing guidelines (mainly the commit message format):
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md#com...
Thanks