Messages in this thread | | | Date | Wed, 12 Oct 2022 09:11:44 +1300 | From | Paulo Miguel Almeida <> | Subject | Re: [PATCH v4] [next] dlm: replace one-element array with fixed size array |
| |
On Tue, Oct 11, 2022 at 01:06:32PM -0700, Kees Cook wrote: > On Wed, Oct 12, 2022 at 09:04:15AM +1300, Paulo Miguel Almeida wrote: > > error = -ENOMEM; > > > > - ls = kzalloc(sizeof(struct dlm_ls) + namelen, GFP_NOFS); > > + ls = kzalloc(sizeof(struct dlm_ls), GFP_NOFS); > ^^^^^^^^^^^^^^^^^^^^ > I think you forgot the suggestion Gustavo had here. :) Preferred style would > be: > sizeof(*ls) > Ooops, I hadn't seen that one =O
Alright, v5 in the making
Paulo A.
| |