Change .8s port name restriction to .15s.

This change corresponds to inet.c 1.13.

MFC after:	1 week
This commit is contained in:
ume 2008-03-18 15:04:05 +00:00
parent ee328ab541
commit d6bcc8a9c7

View File

@ -1103,7 +1103,7 @@ inet6print(struct in6_addr *in6, int port, const char *proto, int numeric)
if (!numeric && port)
GETSERVBYPORT6(port, proto, sp);
if (sp || port == 0)
sprintf(cp, "%.8s", sp ? sp->s_name : "*");
sprintf(cp, "%.15s", sp ? sp->s_name : "*");
else
sprintf(cp, "%d", ntohs((u_short)port));
width = Wflag ? 45 : Aflag ? 18 : 22;