Module: kamailio
Branch: 4.4
Commit: eede8862900030f195ef31f476cea50ab1b56230
URL:
https://github.com/kamailio/kamailio/commit/eede8862900030f195ef31f476cea50…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2017-03-28T15:43:00+02:00
pv: fix for param.count transformation with pv parameter
- reported by GH #1041
(cherry picked from commit f151c26b49d483efbbb27acbb72950d79b8c563d)
(cherry picked from commit a032c4c630ea8eae8fc717bc8d2f5aec956e69e3)
---
Modified: modules/pv/pv_trans.c
---
Diff:
https://github.com/kamailio/kamailio/commit/eede8862900030f195ef31f476cea50…
Patch:
https://github.com/kamailio/kamailio/commit/eede8862900030f195ef31f476cea50…
---
diff --git a/modules/pv/pv_trans.c b/modules/pv/pv_trans.c
index 942803d..dfccc75 100644
--- a/modules/pv/pv_trans.c
+++ b/modules/pv/pv_trans.c
@@ -2624,13 +2624,13 @@ char* tr_parse_paramlist(str* in, trans_t *t)
start_pos = ++p;
_tr_parse_sparam(p, p0, tp, spec, ps, in, s);
t->params = tp;
- tp = 0;
- if (p - start_pos != 1)
+ if (tp->type != TR_PARAM_SPEC && p - start_pos != 1)
{
LM_ERR("invalid separator in transformation: "
"%.*s\n", in->len, in->s);
goto error;
}
+ tp = 0;
while(*p && (*p==' ' || *p=='\t' || *p=='\n')) p++;
if(*p!=TR_RBRACKET)