Module: kamailio
Branch: master
Commit: 3525d6ec7f9fc719651a97e8a9779f13eb14d0fd
URL:
https://github.com/kamailio/kamailio/commit/3525d6ec7f9fc719651a97e8a9779f1…
Author: Carsten Bock <carsten(a)ng-voice.com>
Committer: Carsten Bock <carsten(a)ng-voice.com>
Date: 2017-03-22T13:57:14+01:00
ims_registrar_pcscf: Fix check for following Service-Routes (Route Header present, but
only pointing locally)
---
Modified: src/modules/ims_registrar_pcscf/service_routes.c
---
Diff:
https://github.com/kamailio/kamailio/commit/3525d6ec7f9fc719651a97e8a9779f1…
Patch:
https://github.com/kamailio/kamailio/commit/3525d6ec7f9fc719651a97e8a9779f1…
---
diff --git a/src/modules/ims_registrar_pcscf/service_routes.c
b/src/modules/ims_registrar_pcscf/service_routes.c
index dfb1627..9c5eba8 100644
--- a/src/modules/ims_registrar_pcscf/service_routes.c
+++ b/src/modules/ims_registrar_pcscf/service_routes.c
@@ -413,6 +413,10 @@ int check_service_routes(struct sip_msg* _m, udomain_t* _d) {
}
LM_DBG("num_routes is %d\n", num_routes);
+ if (num_routes == 0) {
+ LM_DBG("Request doesn't have any route headers (except those pointing here),
to check service-route...ignoring\n");
+ goto error;
+ }
for (i=0; i<num_routes; i++) {
LM_DBG("route %d for checking is %s\n", i, routes[i]);
}