Module: kamailio
Branch: 5.5
Commit: 18e85c98bb6eebf9afe83aaa0a832d1c4af46e62
URL:
https://github.com/kamailio/kamailio/commit/18e85c98bb6eebf9afe83aaa0a832d1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2021-06-10T12:27:18+02:00
pv: test for HDR_ERROR_T after header name parsing
(cherry picked from commit c264fbc66a4690b073c72ffa8fc095227ce0ae8b)
---
Modified: src/modules/pv/pv_core.c
---
Diff:
https://github.com/kamailio/kamailio/commit/18e85c98bb6eebf9afe83aaa0a832d1…
Patch:
https://github.com/kamailio/kamailio/commit/18e85c98bb6eebf9afe83aaa0a832d1…
---
diff --git a/src/modules/pv/pv_core.c b/src/modules/pv/pv_core.c
index 103f9dd5ec..6ead708037 100644
--- a/src/modules/pv/pv_core.c
+++ b/src/modules/pv/pv_core.c
@@ -3274,8 +3274,8 @@ int pv_parse_hdr_name(pv_spec_p sp, str *in)
s.s = p;
s.len = in->len+1;
- if (parse_hname2_short(s.s, s.s + s.len, &hdr)==0)
- {
+ parse_hname2_short(s.s, s.s + s.len, &hdr);
+ if(hdr.type==HDR_ERROR_T) {
LM_ERR("error parsing header name [%.*s]\n", s.len, s.s);
goto error;
}