mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2026-04-23 16:56:41 +00:00
Fix propagation of external port after guessing
This commit is contained in:
@@ -107,11 +107,12 @@ public class ComputerDetails {
|
|||||||
}
|
}
|
||||||
if (details.remoteAddress != null) {
|
if (details.remoteAddress != null) {
|
||||||
this.remoteAddress = details.remoteAddress;
|
this.remoteAddress = details.remoteAddress;
|
||||||
|
}
|
||||||
// If the port is unknown, populate it from the external port field
|
else if (this.remoteAddress != null && details.externalPort != 0) {
|
||||||
if (this.remoteAddress.port == 0) {
|
// If we have a remote address already (perhaps via STUN) but our updated details
|
||||||
this.remoteAddress.port = externalPort;
|
// don't have a new one (because GFE doesn't send one), propagate the external
|
||||||
}
|
// port to the current remote address. We may have tried to guess it previously.
|
||||||
|
this.remoteAddress.port = details.externalPort;
|
||||||
}
|
}
|
||||||
if (details.manualAddress != null) {
|
if (details.manualAddress != null) {
|
||||||
this.manualAddress = details.manualAddress;
|
this.manualAddress = details.manualAddress;
|
||||||
|
|||||||
Reference in New Issue
Block a user