Refine nat 1to1 mapping setting (#1094)

Now only set mapping when user_external_ip enabled or node_ip is
explicitly set. If multiple local address resolved to same external
ip, only the first one will be mapped to external, avoid candidate
conflict between different clients.
This commit is contained in:
cnderrauber
2022-10-17 16:11:52 +08:00
committed by GitHub
parent 4161768530
commit 759e3bb1f2
4 changed files with 114 additions and 31 deletions
-3
View File
@@ -199,9 +199,6 @@ func (r *RoomManager) Stop() {
if r.rtcConfig.UDPMux != nil {
_ = r.rtcConfig.UDPMux.Close()
}
if r.rtcConfig.UDPMuxConn != nil {
_ = r.rtcConfig.UDPMuxConn.Close()
}
if r.rtcConfig.TCPMuxListener != nil {
_ = r.rtcConfig.TCPMuxListener.Close()
}