On Mon, 2022-11-14 at 15:04 -0800, Aloka Dixit wrote: > > if (params->mbssid_ies) { > mbssid = params->mbssid_ies; > size += struct_size(new->mbssid_ies, elem, mbssid->cnt); > - size += ieee80211_get_mbssid_beacon_len(mbssid, mbssid->cnt); > + if (params->rnr_ies) { > + rnr = params->rnr_ies; > + size += struct_size(new->rnr_ies, elem, rnr->cnt); > + } Is this right? The struct_size() is only the size of the struct, but you need the size of the elements contained in it here, i.e. the sum of the .len fields? johannes