public static InetAddress getListenHostname(String fullHostname) {
		
		int pos = fullHostname.lastIndexOf(":");
		int pos2 = fullHostname.lastIndexOf(",");
		
		int lastMarker = Math.max(pos, pos2);
		
		if(lastMarker == -1) {
				return null;
		} else {
			pos2++;
			if(pos == -1) {
				return null;
			} else {
				if(pos2 < pos) {
					String hostname = fullHostname.substring(pos2, pos);
					InetAddress address;
					try {
						address = InetAddress.getByName(hostname);
					} catch (UnknownHostException e) {
						Logging.log("Unknown hostname for listen port: " + hostname);
						return null;
					}
					if(MiscUtils.isThisMyIpAddress(address)) {
						return address;
					} else {
						return null;
					}
				} else {
					return null;
				}
			}
		}
		
	}