mirror of
https://github.com/nmap/nmap.git
synced 2025-12-15 20:29:03 +00:00
Get rid of ntohs in ip6_ntop.
Byte-swapping is handled by the initial loop that reads into an array of 16-bit integers. That initial loop was added by me in r29708.
This commit is contained in:
@@ -227,8 +227,7 @@ ip6_ntop(const ip6_addr_t *ip6, char *dst, size_t len)
|
||||
len - (p - dst)) == NULL)
|
||||
return (NULL);
|
||||
return (dst);
|
||||
} else p += sprintf(p, "%x:",
|
||||
ntohs(data[i / 2]));
|
||||
} else p += sprintf(p, "%x:", data[i / 2]);
|
||||
}
|
||||
if (best.base + 2 + best.len == IP6_ADDR_LEN) {
|
||||
*p = '\0';
|
||||
|
||||
Reference in New Issue
Block a user