Beispiel #1
0
 def _send_to_remote_peer(x, idurl, filename, loop_delay):
     print '+++++ PREPARE SENDING TO', idurl
     init(stun.getUDPClient())
     A().debug = True
     contacts.addCorrespondent(idurl)
     reactor.callLater(1, Start)
     ident = identitycache.FromCache(idurl)
     if ident is None:
         print '+++++ REMOTE IDENTITY IS NONE'
         reactor.stop()
         return
     x, udphost, udpport, x = ident.getProtoParts('udp')
     transport_udp_session.SetStateChangedCallbackFunc(lambda index, old, new: _state_changed(index, udphost, new, filename, loop_delay))
Beispiel #2
0
 def _receive_from_remote_peer(x, idurl):
     init(stun.getUDPClient())
     A().debug = True
     contacts.addCorrespondent(idurl)
     reactor.callLater(1, Start)