fix parsing of hostnames when we actually want IP addresses. Upstream-commit: 983b4fc3bfade212bd61e58987e0c5bd32d134ea Component: engine