diff --git a/src/devices.rs b/src/devices.rs index 771d7f4..86ca581 100644 --- a/src/devices.rs +++ b/src/devices.rs @@ -307,8 +307,8 @@ impl TryFrom<&MuxerDevice> for Plist { let mut data = [0u8; 152]; match device.network_address.unwrap() { IpAddr::V4(ip_addr) => { - data[0] = 0x02; - data[1] = 0x00; + data[0] = 10; + data[1] = 0x02; data[2] = 0x00; data[3] = 0x00; let mut i = 4; @@ -318,15 +318,14 @@ impl TryFrom<&MuxerDevice> for Plist { } } IpAddr::V6(ip_addr) => { - data[0] = 0x1E; - data[1] = 0x00; + data[0] = 28; + data[1] = 0x1E; data[2] = 0x00; data[3] = 0x00; data[4] = 0x00; data[5] = 0x00; data[6] = 0x00; - data[7] = 0x00; - let mut i = 8; + let mut i = 16; for byte in ip_addr.octets() { data[i] = byte; i += 1;