Re: [Freeswitch-dev] Bridge problem...

2009-07-14 Thread Anthony Minessale
is this a sip call? are possibly not getting the bye when you hangup? turn on sip trace and debug logging and hangup and watch for what happens On Tue, Jul 14, 2009 at 11:50 AM, Kevin Snow wrote: > OK, thanks. I’ll look at how mod_commands handles this. > > Also, I just realized that the prob

Re: [Freeswitch-dev] Bridge problem...

2009-07-14 Thread Kevin Snow
OK, thanks. I¹ll look at how mod_commands handles this. Also, I just realized that the problem is not that my handlers are not called but that the hangup isn¹t happening. After everybody has literally hung up, using ³show channels² still shows those two channels as active. They haven¹t hung up yet

Re: [Freeswitch-dev] Bridge problem...

2009-07-14 Thread Mathieu Rene
Try using an event hook on state hange instead of a state handler. Or, if you don't need access to the session once its hung up, use a plain event handler. One thing you need to know about threads is that FS spaws its own thread per call. You can do your own stuff in as many threads as you

Re: [Freeswitch-dev] Bridge problem...

2009-07-14 Thread Kevin Snow
Thanks for your help on this, I¹m getting closer but still have something wrong. I changed the code to use the bridge function you mentioned. It does seem to work a little better as the multithreaded bridge sometimes had audio glitches that this method doesn¹t const char* sessionUUID = s

Re: [Freeswitch-dev] Bridge problem...

2009-07-13 Thread Mathieu Rene
On another note, switch_ivr_uuid_bridge() will flush the state handler table for both legs. You need to set them back after. Note that event hooks aren't removed, so you can use switch_core_event_hook_add_state_change() (look in mod_limit for an example) to get a callback on state change. M

Re: [Freeswitch-dev] Bridge problem...

2009-07-13 Thread Mathieu Rene
Kevin, You can't call that function directly, you need to tell the core to bridge the 2 channels together, or else you end up with 2 threads trying to do media on the same thread. Look at switch_ivr_uuid_bridge(const char *originator_uuid, const char *originatee_uuid); Also don't forget

[Freeswitch-dev] Bridge problem...

2009-07-13 Thread Kevin Snow
Hi, In my module (written in C) I spin up a session using the recipe you gave me a few weeks ago. I then use switch_ivr_originate twice to establish two endpoints and bridge them using switch_ivr_multi_threaded_bridge. I inherited some of this code, but I think it¹s using the multithreaded bridge