#### Pre-Submission Checklist - [x] Commit message has the format required by CONTRIBUTING guide - [ ] Commits are split per component (core, individual modules, libs, utils, ...) - [ ] Each component has a single commit (if not, squash them into one commit) - [x] No commits to README files for modules (changes must be done to docbook files in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change - [ ] Small bug fix (non-breaking change which fixes an issue) - [x] New feature (non-breaking change which adds new functionality) - [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist: <!-- Go over all points below, and after creating the PR, tick the checkboxes that apply --> - [ ] PR should be backported to stable branches - [x] Tested changes locally - [x] Related to issue #2308
#### Description add support for trimming an already existing alias parameter when calling `set_contact_alias()`
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2388
-- Commit Summary --
* nathelper: add optional set_contact_alias([trim]) parameter
-- File Changes --
M src/core/dset.c (85) M src/core/dset.h (1) M src/modules/nathelper/doc/nathelper_admin.xml (12) M src/modules/nathelper/nathelper.c (37)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2388.patch https://github.com/kamailio/kamailio/pull/2388.diff
This pull request **introduces 1 alert** when merging f2544789283d7ffbeda019c8a3d96e833bf34cc9 into 798c1c66a7ef34abaf79d49d184853a313aa3f02 - [view on LGTM.com](https://lgtm.com/projects/g/kamailio/kamailio/rev/pr-3425cf6165349e2b8294f00...)
**new alerts:**
* 1 for Local variable hides global variable
Thanks!
If nobody has anything against, this can be merged before branching 5.4 to fix the situation of "strange" UA that take the alias from 200ok of REGISTER and use it for subsequent requests.
Merged #2388 into master.
@eschmidbauer - my comment was to wait a few days before merging to see the opinion of other developers, not to merge.
There is also an issue reported by LGTM scanner: 'Local variable hides global variable', see above comments from their bot.
Apologies, I misunderstood. I can revert the commit
reverted and resubmitted PR (https://github.com/kamailio/kamailio/pull/2390) with update to address the LGTM scanner issue
A fair amount of time should be allowed for comments, considering time zones, traveling, etc ...
With the revert, I noticed that a new function was actually added to the core. If wanted there, then it should have been a separate commit for it. We want commits per components, so maintainers of each component can see easier their code is affected.
ive updated the new PR with 2 separate commits, one for core and one for the module