]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
lsfd: (bugfix) use PRIu32 for prining lport of netlink socket
authorMasatake YAMATO <yamato@redhat.com>
Sat, 8 Nov 2025 02:42:31 +0000 (11:42 +0900)
committerMasatake YAMATO <yamato@redhat.com>
Tue, 9 Dec 2025 21:21:24 +0000 (06:21 +0900)
Fixes #3849

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
(cherry picked from commit 5bbe47432f98a7e391da04157af9906832058ef7)

lsfd-cmd/sock-xinfo.c

index 42d8e0919201c28742f056a5ec8458a1bf5272b3..52e4cf42e1928ebf6e0abd0a72dda1e6ea3b2e60 100644 (file)
@@ -1896,11 +1896,11 @@ static char *netlink_get_name(struct sock_xinfo *sock_xinfo,
        const char *protocol = netlink_decode_protocol(nl->protocol);
 
        if (nl->groups)
-               xasprintf(&str, "protocol=%s lport=%"PRIu16 " groups=%"PRIu32,
+               xasprintf(&str, "protocol=%s lport=%"PRIu32 " groups=%"PRIu32,
                          protocol,
                          nl->lportid, nl->groups);
        else
-               xasprintf(&str, "protocol=%s lport=%"PRIu16,
+               xasprintf(&str, "protocol=%s lport=%"PRIu32,
                          protocol,
                          nl->lportid);
        return str;