hi all,

I write a javascript to bridge two endpoints. The senes is like the following,
A(web+sip.js+wrtc) <--->Freeswitch(sofia+javascript) <---> Twilio sip trunking <---> B(pstn phone).

I tried two methods in Freeswitch javascript to call from A to B:
1. create new sessionB then bridge A to B:
   (1) sessionA.answer() and ring back to A, 
   (2) create new session to B via sip bridge, then break sessionA ringback and park sessionB, 
   (3) bridge(sessionA, sessionB)

2. bridge A to B directly without create sessionB:
   (1) sessionA.answer(),
   (2) sessionA.execute('bridge','sofia/gateway/32d1440c-d13c-44b3-94da-1589daf6e81b/'+sessionA.getVariable('callee_id_number'));

The second one works well. But in the first one, A always loses some audio from B. 
I use tcpdump on my Freeswitch server to check the connection and find that some UDP packets from Freeswitch to A are lost, but the packets from Twillo to Freeswitch are not lose.
It seems that some UDP packet are lost while the Freeswitch relays the udp packets to A.

So, what the difference is between the two methods?  And how can I fix this problem? I need to use the first method to make the call.

Thank!