mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2025-07-19 02:53:05 +00:00
Fix broken de-duplication of computers
This commit is contained in:
parent
314242ab08
commit
0041fc1dab
@ -244,9 +244,12 @@ public class ComputerManagerService extends Service {
|
|||||||
for (PollingTuple tuple : pollingTuples) {
|
for (PollingTuple tuple : pollingTuples) {
|
||||||
// Check if this is the same computer
|
// Check if this is the same computer
|
||||||
if (tuple.computer == details ||
|
if (tuple.computer == details ||
|
||||||
tuple.computer.localIp.equals(details.localIp) ||
|
// If there's no name on one of these computers, compare with the local IP
|
||||||
tuple.computer.remoteIp.equals(details.remoteIp) ||
|
((details.name.isEmpty() || tuple.computer.name.isEmpty()) &&
|
||||||
tuple.computer.name.equals(details.name)) {
|
tuple.computer.localIp.equals(details.localIp)) ||
|
||||||
|
// If there is a name on both computers, compare with name
|
||||||
|
((!details.name.isEmpty() && !tuple.computer.name.isEmpty()) &&
|
||||||
|
tuple.computer.name.equals(details.name))) {
|
||||||
|
|
||||||
// Start a polling thread if polling is active
|
// Start a polling thread if polling is active
|
||||||
if (pollingActive && tuple.thread == null) {
|
if (pollingActive && tuple.thread == null) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user