netstat patch

看板DFBSD_submit作者時間21年前 (2004/10/16 07:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/2 (看更多)
hi, it's small patch that fix wrong display of inet6 ports, like 0 udp4 0 0 127.0.0.1.500 *.* 0 udp6 0 0 fe80:1::230:84ff.500 *.* and 0 udp4 0 0 127.0.0.1.500 *.* 0 udp6 0 0 fe80:1::230:84ff.500 *.* after patch. Index: inet6.c =================================================================== RCS file: /home/dcvs/src/usr.bin/netstat/inet6.c,v retrieving revision 1.4 diff -u -r1.4 inet6.c --- inet6.c 30 Aug 2004 18:06:50 -0000 1.4 +++ inet6.c 16 Oct 2004 01:17:23 -0000 @@ -1057,7 +1057,7 @@ sprintf(cp, "%.8s", sp ? sp->s_name : "*"); else sprintf(cp, "%d", ntohs((u_short)port)); - width = Wflag ? 45 : Aflag ? 18 : 22; + width = Wflag ? 45 : Aflag ? 17 : 21; printf("%-*.*s ", width, width, line); } --
文章代碼(AID): #11S5tq00 (DFBSD_submit)
文章代碼(AID): #11S5tq00 (DFBSD_submit)