### Description
KEMI onsend_route is not called unless there is a placeholder/dummy routing block.
```
## without this block, core will never call KEMI->onsend_route
onsend_route {
## do nothing
}
```
### Troubleshooting
#### Reproduction
1. In KEMI create ksr_onsend_route(). Observe that this function is never invoked.
2. Add a route block:
```
onsend_route {
## do nothing
}
```
Now observe, that KEMI ksr_onsend_route() is called.
#### Debugging Data
#### Log Messages
#### SIP Traffic
### Possible Solutions
Not really a problem, just a surprise to the KEMI user. Possibly, document that in order
for the KEMI function to be called, the configuration file needs a dummy routing block for
onsend_route.
### Additional Information
The reason is the following logic:
onsend.h:
`ret=keng->froute(orig_msg, ONSEND_ROUTE, NULL, NULL);`
This line is called only if `onsend_rt.rlist[DEFAULT_RT]` is non-NULL, but this array is
initialized only if the `onsend_route` block exists.
* **Kamailio Version** - 5.1, master
* **Operating System**:
Linux CentOS 7.4
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/1474