[asterisk-commits] oej: branch oej/sip-callpickup-1.2 r73671 - /team/oej/sip-callpickup-1.2/chan...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Jul 6 07:13:51 CDT 2007


Author: oej
Date: Fri Jul  6 07:13:50 2007
New Revision: 73671

URL: http://svn.digium.com/view/asterisk?view=rev&rev=73671
Log:
Adding fake headers. Go go go.

Modified:
    team/oej/sip-callpickup-1.2/channels/chan_sip.c

Modified: team/oej/sip-callpickup-1.2/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/team/oej/sip-callpickup-1.2/channels/chan_sip.c?view=diff&rev=73671&r1=73670&r2=73671
==============================================================================
--- team/oej/sip-callpickup-1.2/channels/chan_sip.c (original)
+++ team/oej/sip-callpickup-1.2/channels/chan_sip.c Fri Jul  6 07:13:50 2007
@@ -5325,11 +5325,12 @@
 	case DIALOG_INFO_XML: /* SNOM subscribes in this format */
 		ast_build_string(&t, &maxbytes, "<?xml version=\"1.0\"?>\n");
 		ast_build_string(&t, &maxbytes, "<dialog-info xmlns=\"urn:ietf:params:xml:ns:dialog-info\" version=\"%d\" state=\"%s\" entity=\"%s\">\n", p->dialogver++, full ? "full":"partial", mto);
-		if ((state & AST_EXTENSION_RINGING) && global_notifyringing)
-			ast_build_string(&t, &maxbytes, "<dialog id=\"%s\" direction=\"recipient\">\n", p->exten);
+		if ((state & AST_EXTENSION_RINGING) && global_notifyringing) {
+			char ringbuf[BUFSIZ/2] = "";
 			if (channel)
-				ast_build_string(&t, &maxbytes, "<!-- Asterisk channel %s -->\n", channel);
-		else
+				snprintf(ringbuf, sizeof(ringbuf), "call-id=\"astpickup--%s--%s--%s\" local-tag=\"%s\" remote-tag=\"%s\"", global_realm, p->exten, channel, "itag", "rtag");
+			ast_build_string(&t, &maxbytes, "<dialog id=\"%s\" direction=\"recipient\" %s>\n", p->exten, ringbuf);
+		} else
 			ast_build_string(&t, &maxbytes, "<dialog id=\"%s\">\n", p->exten);
 		ast_build_string(&t, &maxbytes, "<state>%s</state>\n", statestring);
 		ast_build_string(&t, &maxbytes, "</dialog>\n</dialog-info>\n");




More information about the asterisk-commits mailing list