[OpenSIPS-Devel] [opensips] When t_relay returns, the global variable route_type is not set back to REQUEST_ROUTE or FAILURE_ROUTE (#365)
mikomarrache
notifications at github.com
Sun Oct 19 12:28:33 CEST 2014
Hi,
```
route {
if(!route(NEXT_HOP)) {
......
}
while(!t_relay("2")) {
if(!route(NEXT_HOP)) {
send_reply("500", "Error");
exit;
}
}
}
route[NEXT_HOP] {
............
t_on_branch("branch_changes");
............
}
```
As you can see, the route block NEXT_HOP computes the next hop and arms a branch route for processing specific to the selected next hop. When t_relay is called, the branch route is executed but may be dropped (using drop() ) if some condition is met. In case the branch is dropped, t_relay returns an error and the next hop is computed again. If no next hop is found, a reply is returned. However, I get the following errors when the reply is returned:
```
CRITICAL:tm:w_t_reply: unsupported route_type (8)
ERROR:signaling:sig_send_reply_mod: failed to send reply with tm module
```
t_reply can't be called from a branch route. I expected the global variable route_type to be set back to REQUEST_ROUTE but it is not the case.
Is it a bug?
Thanks,
Mickael
---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/365
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/devel/attachments/20141019/26b6a7d6/attachment.htm>
More information about the Devel
mailing list