Module: sip-router
Branch: master
Commit: 40b37899aaadd1518d812c4a32aeab330b864cb4
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=40b3789…
Author: Andreas Granig <agranig(a)sipwise.com>
Committer: Andreas Granig <agranig(a)sipwise.com>
Date: Wed Jul 11 12:52:38 2012 +0200
modules_k/uac: fix handling of empty display-part.
This re-enables the feature to strip the display name by setting
an empty string, like uac_replace_from("", "$var(from)");
---
modules_k/uac/uac.c | 11 ++++-------
1 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/modules_k/uac/uac.c b/modules_k/uac/uac.c
index 8de09b1..763dd5a 100644
--- a/modules_k/uac/uac.c
+++ b/modules_k/uac/uac.c
@@ -435,14 +435,11 @@ static int fixup_replace_disp_uri(void** param, int param_no)
s.len += 2;
}
}
- if(s.len!=0)
+ if(pv_parse_format(&s ,&model)<0)
{
- if(pv_parse_format(&s ,&model)<0)
- {
- LM_ERR("wrong format [%s] for param no %d!\n", s.s, param_no);
- pkg_free(s.s);
- return E_UNSPEC;
- }
+ LM_ERR("wrong format [%s] for param no %d!\n", s.s, param_no);
+ pkg_free(s.s);
+ return E_UNSPEC;
}
*param = (void*)model;