package eu.mondo.utils;

import java.io.IOException;
import java.net.Socket;

public class NetworkUtils {
	
	public static String getLocalIpAddress() throws IOException{
		Socket socket = new Socket("google.com", 80);
		String result = socket.getLocalAddress().getHostAddress();
		socket.close();
		return result;
	}

}

@@ -62,22 +62,27 @@
 ava.net.
-Socket
+InetAddress
 ;%0A%0Apubli
@@ -175,147 +175,127 @@
 %0A%09%09S
-ocket socket
+tring hostName
  = 
+I
 ne
-w Socket(%22google.com%22, 80);%0A%09%09String result = socket.getLocalAddress().getHostAddress();%0A%09%09socket.close();%0A%09%09return result
+tAddress.getLocalHost().getHostName();%0A%09    return InetAddress.getByName(hostName).getHostAddress()
 ;%0A%09%7D

Fix NetworkUtils.getLocalIpAddress