On Wed, 2020-08-19 at 12:10 -0700, Jakub Kicinski wrote:
> > + memset(&state->policies[state->n_alloc], 0,
> > + sizeof(state->policies[0]) * (n_alloc - state->n_alloc));
>
> [flex_]array_size() ? To avoid the inevitable follow up from a bot..
Yeah, hmm.
I suppose you know this but
On Wed, 19 Aug 2020 12:22:55 +0200 Johannes Berg wrote:
> From: Johannes Berg
>
> Evidently, when I did this previously, we didn't have more than
> 10 policies and didn't run into the reallocation path, because
> it's missing a memset() for the unused policies. Fix that.
>
> Fixes: d07dcf9aadd6
From: Johannes Berg
Evidently, when I did this previously, we didn't have more than
10 policies and didn't run into the reallocation path, because
it's missing a memset() for the unused policies. Fix that.
Fixes: d07dcf9aadd6 ("netlink: add infrastructure to expose policies to
userspace")
Signe