-/* $OpenBSD: ieee80211_input.c,v 1.189 2017/03/13 07:44:10 stsp Exp $ */
+/* $OpenBSD: ieee80211_input.c,v 1.190 2017/04/09 18:15:32 dhill Exp $ */
/*-
* Copyright (c) 2001 Atsushi Onoe
ba->ba_winstart = ssn;
ba->ba_winend = (ba->ba_winstart + ba->ba_winsize - 1) & 0xfff;
/* allocate and setup our reordering buffer */
- ba->ba_buf = malloc(IEEE80211_BA_MAX_WINSZ * sizeof(*ba->ba_buf),
+ ba->ba_buf = mallocarray(IEEE80211_BA_MAX_WINSZ, sizeof(*ba->ba_buf),
M_DEVBUF, M_NOWAIT | M_ZERO);
if (ba->ba_buf == NULL)
goto refuse;