[asterisk-commits] mmichelson: branch mmichelson/direct_media r382535 - /team/mmichelson/direct_...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Mar 6 13:34:45 CST 2013


Author: mmichelson
Date: Wed Mar  6 13:34:42 2013
New Revision: 382535

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=382535
Log:
Remember to tell the RTP layer to update peers when an INVITE transaction terminates.

At this point, I have direct media working properly at all times (seemingly). Running
many many calls, I see reinvites sent out to both call legs with proper IP addresses
in the SDPs. Furthermore, when the call ends, I see the media get reinvited back to
Asterisk, and this reinvite serializes properly with BYEs that get sent out.

The next step is to work on off-nominal situations, such as a reinvite being rejected,
especially if it is rejected with a 491 response.


Modified:
    team/mmichelson/direct_media/res/res_sip_session.c

Modified: team/mmichelson/direct_media/res/res_sip_session.c
URL: http://svnview.digium.com/svn/asterisk/team/mmichelson/direct_media/res/res_sip_session.c?view=diff&rev=382535&r1=382534&r2=382535
==============================================================================
--- team/mmichelson/direct_media/res/res_sip_session.c (original)
+++ team/mmichelson/direct_media/res/res_sip_session.c Wed Mar  6 13:34:42 2013
@@ -380,6 +380,9 @@
 		/* No delayed request to send, so just return */
 		return;
 	}
+
+	ast_log(LOG_NOTICE, "Queuing delayed request to run for %s\n",
+			S_OR(ast_sorcery_object_get_id(session->endpoint), "outbound"));
 
 	ao2_ref(session, +1);
 	ast_sip_push_task(session->serializer, send_delayed_request, session);
@@ -976,6 +979,9 @@
 	if (tsx->method.id == PJSIP_INVITE_METHOD && tsx->state == PJSIP_TSX_STATE_TERMINATED) {
 		struct ast_sip_session *session = inv->mod_data[session_module.id];
 		queue_delayed_request(session);
+		if (session->endpoint->direct_media && session->channel) {
+			ast_queue_control(session->channel, AST_CONTROL_SRCCHANGE);
+		}
 	}
 }
 




More information about the asterisk-commits mailing list