1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-27 09:59:04 +00:00

Don't print an rDNS record if it is blank.

This commit is contained in:
david
2009-10-26 21:17:13 +00:00
parent 01f70c5432
commit d837d751bc

View File

@@ -1428,6 +1428,7 @@ void write_host_header(Target *currenths) {
write_host_status(currenths, o.resolve_all);
/* Print reverse DNS if it differs. */
if (currenths->TargetName() != NULL
&& currenths->HostName() != NULL && currenths->HostName()[0] != '\0'
&& strcmp(currenths->TargetName(), currenths->HostName()) != 0) {
log_write(LOG_PLAIN, "rDNS record for %s: %s\n",
currenths->targetipstr(), currenths->HostName());