netstat: fix format string on 32-bit archs
This commit is contained in:
parent
153643a5bc
commit
79111aa26f
@ -129,7 +129,7 @@ prepare_ifmap_netlink(struct snl_state *ss, size_t *pifmap_size)
|
|||||||
if (link.ifi_index >= ifmap_size) {
|
if (link.ifi_index >= ifmap_size) {
|
||||||
size_t size = roundup2(link.ifi_index + 1, 32) * sizeof(struct ifmap_entry);
|
size_t size = roundup2(link.ifi_index + 1, 32) * sizeof(struct ifmap_entry);
|
||||||
if ((ifmap = realloc(ifmap, size)) == NULL)
|
if ((ifmap = realloc(ifmap, size)) == NULL)
|
||||||
errx(2, "realloc(%lu) failed", size);
|
errx(2, "realloc(%zu) failed", size);
|
||||||
memset(&ifmap[ifmap_size], 0,
|
memset(&ifmap[ifmap_size], 0,
|
||||||
size - ifmap_size *
|
size - ifmap_size *
|
||||||
sizeof(struct ifmap_entry));
|
sizeof(struct ifmap_entry));
|
||||||
|
Loading…
Reference in New Issue
Block a user