I do not understand how does it work. Can anyone explain me that from jni level? Does it call getnameinfo?
https://github.com/google/guava/blob/master/guava/src/com/google/common/net/InetAddresses.java
I do not understand how does it work. Can anyone explain me that from jni level? Does it call getnameinfo?
https://github.com/google/guava/blob/master/guava/src/com/google/common/net/InetAddresses.java
It does not get the hostname at all. ipStringToBytes
converts an IPv4 or IPv6 address into raw bytes and uses that to call bytesToInetAddress
which calls InetAddress.getByAddress which returns uses a raw IP address.