Home > other >  Why udp penetrate side can receive in establishing links to information but the original back to end
Why udp penetrate side can receive in establishing links to information but the original back to end

Time:10-04

When doing the udp penetrate, the same telecom operators can be successful through,
But when the cross operator, such as telecommunications and mobile between do make hole penetration, cannot succeed, caught found in mobile telecommunications peer receives the package come over there, in the program also receives the package and reply to the original road, each other can't get forget to package, can't understand why,
Code signal is as follows:
 
Struct sockaddr_in peer_sockaddr;

Recvfrom (listen_socket, & amp; Peer_sockaddr);//received sent to end hole package, address for peer_sockaddr
Sendto (listen_socket peer_sockaddr));//use the original road peer_sockaddr return



CodePudding user response:

My UDP penetrate, both of us can receive the other package, can see my question?
http://bbs.csdn.net/topics/392201967

CodePudding user response:

Because the mobile is NAT4, your telecom should be NAT3, NAT4 and NAT3 cannot make hole completely successful
  • Related