[svn-commits] mmichelson: branch group/CCSS r230507 - /team/group/CCSS/channels/chan_sip.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Nov 19 15:11:44 CST 2009


Author: mmichelson
Date: Thu Nov 19 15:11:40 2009
New Revision: 230507

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=230507
Log:
* Add destination field to sip_epa_entry so that requests can be
  routed to the appropriate place
* Use the destinatino field to call create_addr in transmit_publish
* Use correct unref call


Modified:
    team/group/CCSS/channels/chan_sip.c

Modified: team/group/CCSS/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/group/CCSS/channels/chan_sip.c?view=diff&rev=230507&r1=230506&r2=230507
==============================================================================
--- team/group/CCSS/channels/chan_sip.c (original)
+++ team/group/CCSS/channels/chan_sip.c Thu Nov 19 15:11:40 2009
@@ -1685,6 +1685,11 @@
    	 * entry belongs.
    	 */
 	const char *event;
+	/* The destination to which this EPA should send
+	 * PUBLISHes. This may be the name of a SIP peer
+	 * or a hostname.
+	 */
+	char destination[SIPBUFSIZE];
 	/* Each event package will have data
    	 * that pertains only to that event package
    	 * and doesn't make sense to other event
@@ -11731,6 +11736,8 @@
 
 	sip_alloc(NULL, NULL, 0, SIP_PUBLISH, NULL);
 
+	create_addr(pvt, epa_entry->destination, NULL, TRUE);
+
 	req.method = SIP_PUBLISH;
 
 	pvt->branch = ast_random();
@@ -11760,7 +11767,7 @@
 	pvt->epa_entry = epa_entry;
 
 	send_request(pvt, &req, XMIT_RELIABLE, INITIAL_CSEQ);
-	sip_pvt_unref(pvt, "Done with the sip_pvt allocated for transmitting PUBLISH");
+	dialog_unref(pvt, "Done with the sip_pvt allocated for transmitting PUBLISH");
 
 	return 0;
 }




More information about the svn-commits mailing list