Add additional ports and addresses for WoL

This commit is contained in:
Cameron Gutman 2019-07-27 17:22:13 -04:00
parent 0b0181f35c
commit 613c068523

View File

@ -12,7 +12,7 @@ import com.limelight.nvstream.http.ComputerDetails;
public class WakeOnLanSender {
private static final int[] PORTS_TO_TRY = new int[] {
7, 9, // Standard WOL ports
47998, 47999, 48000 // Ports opened by GFE
47998, 47999, 48000, 48002, 48010 // Ports opened by GFE
};
public static void sendWolPacket(ComputerDetails computer) throws IOException {
@ -26,7 +26,7 @@ public class WakeOnLanSender {
// The broadcast address is required to avoid stale ARP cache entries
// making the sleeping machine unreachable.
for (String unresolvedAddress : new String[] {
computer.localAddress, computer.remoteAddress, computer.manualAddress, "255.255.255.255"
computer.localAddress, computer.remoteAddress, computer.manualAddress, computer.ipv6Address, "255.255.255.255"
}) {
if (unresolvedAddress == null) {
continue;