On 15 Nov 2009, at 21:31, Bogdan-Andrei Iancu wrote: >> The other problem is how to end the media proxy session. The >> transaction flags set for the Invite are >> not visible in the local_route block when it is handling the >> internally generated BYE's so I cannot >> try the normal checks that would be used in the main route block >> for BYE. Perhaps I should just call >> end_media_session(), but will it even work from local_route? If I >> change my script to start using >> engage_media_proxy() will I lose the flexibility of being able to >> check which calls need media proxy >> and which don't? I don't want them all using it - only those with >> far-end NAT. >> > Shouldn't the media proxy automatically stop when the dialog is > destroyed ? if you use the enagage_mediaproxy(), I think you do not > have > to explicitly terminate the relay session as the this op will be done > based on the "dialog destroyed" event.
When using engage_media_proxy() the media session will terminated automatically when the dialog ends. However if I understand it right, his problem is that when using use_media_proxy and end_media_session he has to do that manually and the local_route is triggered twice (once for each BYE). Now calling end_media_session twice, should do no harm, but it'll log an error since it will not find the session the second time. -- Dan _______________________________________________ Users mailing list [email protected] http://lists.opensips.org/cgi-bin/mailman/listinfo/users
