1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-20 22:49:01 +00:00

fix a couple bugs found by Jochen (voss at seehuhn.de

This commit is contained in:
fyodor
2006-11-06 02:14:35 +00:00
parent b39aa96073
commit 9a1fece75d
8 changed files with 175 additions and 67 deletions

View File

@@ -500,7 +500,7 @@ static const char *ippackethdrinfo(const u8 *packet, u32 len) {
*p++ = 'A';
snprintf(buf, sizeof(buf), " ack=%lu",
(unsigned long) ntohl(tcp->th_ack));
strncat(tcpinfo, buf, sizeof(tcpinfo));
strncat(tcpinfo, buf, sizeof(tcpinfo) - 1);
}
if (tcp->th_flags & TH_URG) *p++ = 'U';
if (tcp->th_flags & TH_ECE) *p++ = 'E'; /* rfc 2481/3168 */