[asterisk-commits] file: trunk r66314 - /trunk/channels/chan_sip.c
asterisk-commits at lists.digium.com
asterisk-commits at lists.digium.com
Mon May 28 16:24:05 MST 2007
Author: file
Date: Mon May 28 18:24:04 2007
New Revision: 66314
URL: http://svn.digium.com/view/asterisk?view=rev&rev=66314
Log:
Due to the way stringfields work the value of the url pointer will always be non-NULL so we have to use ast_strlen_zero to make sure it is not empty. (issue #9821 reported by pj)
Modified:
trunk/channels/chan_sip.c
Modified: trunk/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_sip.c?view=diff&rev=66314&r1=66313&r2=66314
==============================================================================
--- trunk/channels/chan_sip.c (original)
+++ trunk/channels/chan_sip.c Mon May 28 18:24:04 2007
@@ -6150,7 +6150,7 @@
add_header(resp, "Contact", p->our_contact);
}
- if (p->url) {
+ if (!ast_strlen_zero(p->url)) {
add_header(resp, "Access-URL", p->url);
ast_string_field_free(p, url);
}
@@ -6260,7 +6260,7 @@
if (!ast_strlen_zero(p->rpid))
add_header(req, "Remote-Party-ID", p->rpid);
- if (p->url) {
+ if (!ast_strlen_zero(p->url)) {
add_header(req, "Access-URL", p->url);
ast_string_field_free(p, url);
}
More information about the asterisk-commits
mailing list