Module: sip-router Branch: kamailio_3.0 Commit: 9223d7a189c64b6a3dbe8c66edf08ddc16f3fd4f URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=9223d7a1...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: Thu Apr 22 10:35:33 2010 +0200
dialog(k): populate bind addr before any error
- setting bind addr attribute in populate_leg_info() takes place before any parsing error may occur, to be sure it is set, avoiding extra check for null value when updating db - reported by Kelvin Chua - credits to Timo Reimann for troubleshooting (cherry picked from commit fd68980dc6f3de03a432f478c124852c23a1d1b2)
---
modules_k/dialog/dlg_handlers.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/modules_k/dialog/dlg_handlers.c b/modules_k/dialog/dlg_handlers.c index 1091777..3b671ab 100644 --- a/modules_k/dialog/dlg_handlers.c +++ b/modules_k/dialog/dlg_handlers.c @@ -200,6 +200,8 @@ int populate_leg_info( struct dlg_cell *dlg, struct sip_msg *msg, str contact; str rr_set;
+ dlg->bind_addr[leg] = msg->rcv.bind_address; + /* extract the cseq number as string */ if (leg==DLG_CALLER_LEG) { if((!msg->cseq && (parse_headers(msg,HDR_CSEQ_F,0)<0 || !msg->cseq)) @@ -269,7 +271,6 @@ int populate_leg_info( struct dlg_cell *dlg, struct sip_msg *msg, goto error0; }
- dlg->bind_addr[leg] = msg->rcv.bind_address; if (rr_set.s) pkg_free(rr_set.s);
return 0;
2010/4/22 Daniel-Constantin Mierla miconda@gmail.com:
dialog(k): populate bind addr before any error
- setting bind addr attribute in populate_leg_info() takes place before
any parsing error may occur, to be sure it is set, avoiding extra check for null value when updating db
Hi, IMHO kamailio 1.5 version should also be fixed. Could I commit the changes? perhaps you already plan to do it?
Thanks.
On 4/22/10 12:20 PM, Iñaki Baz Castillo wrote:
2010/4/22 Daniel-Constantin Mierlamiconda@gmail.com:
dialog(k): populate bind addr before any error
- setting bind addr attribute in populate_leg_info() takes place before any parsing error may occur, to be sure it is set, avoiding extra check for null value when updating db
Hi, IMHO kamailio 1.5 version should also be fixed. Could I commit the changes? perhaps you already plan to do it?
yes, 1.x series should be fixed as well. Please go ahead (it is in my todo for later, since i got in something else for now), but if you have time, then is perfect for me.
Thanks, Daniel
Thanks.
2010/4/22 Daniel-Constantin Mierla miconda@gmail.com:
On 4/22/10 12:20 PM, Iñaki Baz Castillo wrote:
2010/4/22 Daniel-Constantin Mierlamiconda@gmail.com:
dialog(k): populate bind addr before any error
- setting bind addr attribute in populate_leg_info() takes place before
any parsing error may occur, to be sure it is set, avoiding extra check for null value when updating db
Hi, IMHO kamailio 1.5 version should also be fixed. Could I commit the changes? perhaps you already plan to do it?
yes, 1.x series should be fixed as well. Please go ahead (it is in my todo for later, since i got in something else for now), but if you have time, then is perfect for me.
Ok, I'll do it in a few minutes.
Thanks a lot.