From bf29b139bd0f273e4f8fec462f77ae8d218bedff Mon Sep 17 00:00:00 2001 From: david Date: Tue, 27 Oct 2009 06:16:22 +0000 Subject: [PATCH] Only print the first warning that a name resolves to multiple addresses (the one that happens right after then name is resolved) with -vv. That information is also printed out above the ports table later. --- TargetGroup.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TargetGroup.cc b/TargetGroup.cc index 3547d24ae..dcf4237fd 100644 --- a/TargetGroup.cc +++ b/TargetGroup.cc @@ -227,7 +227,7 @@ int TargetGroup::parse_expr(const char * const target_expr, int af) { count++; } - if (count > 1) + if (count > 1 && o.verbose > 1) error("Warning: Hostname %s resolves to %d IPs. Using %s.", target_net, count, inet_ntoa(*((struct in_addr *)target->h_addr_list[0]))); } else { error("Failed to resolve given hostname/IP: %s. Note that you can't use '/mask' AND '1-4,7,100-' style IP ranges", target_net);