diff options
| author | Michael Tuexen <tuexen@FreeBSD.org> | 2026-07-13 09:08:01 +0000 |
|---|---|---|
| committer | Michael Tuexen <tuexen@FreeBSD.org> | 2026-07-13 09:13:04 +0000 |
| commit | f2f50c80ae27a97a66b8d4a1b5dd6ee9d63ff18f (patch) | |
| tree | 4cbb0bf19c799d858c329fc57663e9a4d4c9e957 | |
| parent | 920518cf2e75012135104886d92814c048baa2fb (diff) | |
sockstat: fix SCTP support
Provide a name for SCTP sockets.
Fixes: 8b2b62b49d88 ("sockstat: consolidate unix(4) protocols in the array of protocols")
| -rw-r--r-- | usr.bin/sockstat/main.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/usr.bin/sockstat/main.c b/usr.bin/sockstat/main.c index 0edf8dcbd431..7acfdc08b0a6 100644 --- a/usr.bin/sockstat/main.c +++ b/usr.bin/sockstat/main.c @@ -398,6 +398,7 @@ gather_sctp(struct proto *proto) xo_err(1, "malloc()"); sock->socket = xinpcb->socket; sock->proto = proto; + sock->protoname = proto->name; if (xinpcb->maxqlen == 0) sock->state = SCTP_CLOSED; else @@ -498,6 +499,7 @@ gather_sctp(struct proto *proto) xo_err(1, "malloc()"); sock->socket = xinpcb->socket; sock->proto = proto; + sock->protoname = proto->name; sock->state = (int)xstcb->state; if (xinpcb->flags & SCTP_PCB_FLAGS_BOUND_V6) { sock->family = AF_INET6; |
