diff options
| author | Pedro F. Giffuni <pfg@FreeBSD.org> | 2018-01-13 22:30:30 +0000 |
|---|---|---|
| committer | Pedro F. Giffuni <pfg@FreeBSD.org> | 2018-01-13 22:30:30 +0000 |
| commit | 26c1d774b55c4db79bca772941883244986e6f44 (patch) | |
| tree | 0d4a99e9eba470c0808a66d7d3f857c9f36446fa /sys/dev/netmap | |
| parent | a019e26c0f76f5fd5c401cd87554ef2d5efc36ca (diff) | |
Notes
Diffstat (limited to 'sys/dev/netmap')
| -rw-r--r-- | sys/dev/netmap/if_ptnet.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/netmap/if_ptnet.c b/sys/dev/netmap/if_ptnet.c index 4c7072774df4..5fea3510dc62 100644 --- a/sys/dev/netmap/if_ptnet.c +++ b/sys/dev/netmap/if_ptnet.c @@ -351,7 +351,7 @@ ptnet_attach(device_t dev) sc->num_tx_rings = num_tx_rings; /* Allocate and initialize per-queue data structures. */ - sc->queues = malloc(sizeof(struct ptnet_queue) * sc->num_rings, + sc->queues = mallocarray(sc->num_rings, sizeof(struct ptnet_queue), M_DEVBUF, M_NOWAIT | M_ZERO); if (sc->queues == NULL) { err = ENOMEM; |
