From 7b7be6aa5bae9ec22aafad817dcc937531ecf9f0 Mon Sep 17 00:00:00 2001 From: Vladimir Osipov Date: Thu, 2 Jan 2020 00:03:54 +0200 Subject: [PATCH] Assure `host` is always an IP address (#69) Use `InetAddress.getHostAddress()` instead of `InetAddress.getHostName()` to get the host IP. The second one sometimes returns a textual name of the local host and this info is not really useful as a source address unless there's a way to resolve that name. --- android/src/main/java/com/tradle/react/UdpReceiverTask.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/src/main/java/com/tradle/react/UdpReceiverTask.java b/android/src/main/java/com/tradle/react/UdpReceiverTask.java index ff45ce68..75eaa072 100644 --- a/android/src/main/java/com/tradle/react/UdpReceiverTask.java +++ b/android/src/main/java/com/tradle/react/UdpReceiverTask.java @@ -47,7 +47,7 @@ protected Void doInBackground(Pair