Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F163337407
D54375.id168626.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
544 B
Referenced Files
None
Subscribers
None
D54375.id168626.diff
View Options
diff --git a/usr.bin/sockstat/main.c b/usr.bin/sockstat/main.c
--- a/usr.bin/sockstat/main.c
+++ b/usr.bin/sockstat/main.c
@@ -962,6 +962,11 @@
xo_emit("{:port/%d}", port);
return 0;
}
+ if (ss->ss_family == AF_INET6 && !IN6_IS_ADDR_UNSPECIFIED(&sstosin6(ss)->sin6_addr)) {
+ if (port == 0)
+ return snprintf(buf, bufsize, "[%s]:*", addrstr);
+ return snprintf(buf, bufsize, "[%s]:%d", addrstr, port);
+ }
if (port == 0)
return snprintf(buf, bufsize, "%s:*", addrstr);
return snprintf(buf, bufsize, "%s:%d", addrstr, port);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jul 23, 6:23 AM (25 m, 7 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35394284
Default Alt Text
D54375.id168626.diff (544 B)
Attached To
Mode
D54375: sockstat: Surround explicit IPv6 addresses with brackets
Attached
Detach File
Event Timeline
Log In to Comment