Simplify some overly complex code so that both humans and Coverity
have a better chance of understanding it. Reported by: Coverity CID: 1009684, 1006931
This commit is contained in:
parent
4238b561f0
commit
16a9eab953
@ -609,12 +609,13 @@ reply_proc(void *res, struct netbuf *who, struct netconfig *nconf)
|
||||
} else {
|
||||
hostname = hostbuf;
|
||||
}
|
||||
if (!(uaddr = taddr2uaddr(nconf, who))) {
|
||||
uaddr = UNKNOWN;
|
||||
}
|
||||
printf("%s\t%s\n", uaddr, hostname);
|
||||
if (strcmp(uaddr, UNKNOWN))
|
||||
uaddr = taddr2uaddr(nconf, who);
|
||||
if (uaddr == NULL) {
|
||||
printf("%s\t%s\n", UNKNOWN, hostname);
|
||||
} else {
|
||||
printf("%s\t%s\n", uaddr, hostname);
|
||||
free((char *)uaddr);
|
||||
}
|
||||
return (FALSE);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user