-
由 Alexander Graf 提交于
We store all struct types in an array of static size without ever checking whether we overrun it. Of course some day someone (like me in another, ancient ALSA enabling patch set) will run into the limit without realizing it. So let's make the allocation dynamic. We already know the number of structs that we want to allocate, so we only need to pass the variable into the respective piece of code. Also, to ensure we don't accidently overwrite random memory, add some asserts to sanity check whether a thunk is actually part of our array. Signed-off-by: NAlexander Graf <agraf@suse.de> Signed-off-by: NRiku Voipio <riku.voipio@linaro.org>
8be656b8