Module: sip-router
Branch: master
Commit: c77aaf38eafe1d3549d266feebf76ac0b50738ea
URL:    
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=c77aaf38eafe1d3549d266feebf76ac0b50738ea

Author: Daniel-Constantin Mierla <[email protected]>
Committer: Daniel-Constantin Mierla <[email protected]>
Date:   Thu Nov 21 19:09:43 2013 +0100

sl: allow send_reply() in the route block types supported by t_reply() and 
sl_send_reply()

- reported by Juha Heinanen, FS#362

---

 modules/sl/sl.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/modules/sl/sl.c b/modules/sl/sl.c
index ab5e737..fb8a1ee 100644
--- a/modules/sl/sl.c
+++ b/modules/sl/sl.c
@@ -99,7 +99,7 @@ static cmd_export_t cmds[]={
        {"sl_reply",       w_sl_send_reply,             2, fixup_sl_reply,
                REQUEST_ROUTE},
        {"send_reply",     w_send_reply,                2, fixup_sl_reply,
-               REQUEST_ROUTE|BRANCH_ROUTE|FAILURE_ROUTE},
+               REQUEST_ROUTE|ONREPLY_ROUTE|FAILURE_ROUTE},
        {"sl_reply_error", w_sl_reply_error,            0, 0,
                REQUEST_ROUTE},
        {"sl_forward_reply",  w_sl_forward_reply0,      0, 0,
@@ -282,6 +282,9 @@ int send_reply(struct sip_msg *msg, int code, str *reason)
                }
        }
 
+       if(msg->first_line.type==SIP_REPLY)
+               goto error;
+
        LM_DBG("reply in stateless mode (sl)\n");
        ret = sl_send_reply(msg, code, r);
 


_______________________________________________
sr-dev mailing list
[email protected]
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev

Reply via email to