Closed Douile closed 1 year ago
Sorry for all the force pushes, had some problems with my editor auto-formatting code I didn't want to touch.
Looks great, thanks!
Looking back at this, it could be a improvement to use std::net::SocketAddr
, This would support IPv4 + 6 and it would include the port so that the address is contained in 1.
Very true, that would also allow removing this conversion from ip address + port num -> string -> SocketAddress. https://github.com/gamedig/rust-gamedig/blob/main/src/socket.rs#L32
Agreed, I will take care of this tomorrow if someone doesnt until then.
Replace usages of Ipv4Addr with IpAddr which allows the use of either Ipv4 or Ipv6.
This patch essentially consists of running: "sed -i 's/Ipv4Addr/IpAddr/g' src/*/.rs" and fixing the errors.
Closes #39