diff options
| author | Remi Pommarel <[email protected]> | 2025-01-28 15:11:06 +0000 |
|---|---|---|
| committer | Simon Wunderlich <[email protected]> | 2025-01-28 21:06:56 +0000 |
| commit | f4c9c2cc827d803159730b1da813a0c595969831 (patch) | |
| tree | 179921a9f4e107bf64c0280e7d93f01575ae223f /scripts/rustdoc_test_gen.rs | |
| parent | batman-adv: Drop unmanaged ELP metric worker (diff) | |
| download | kernel-f4c9c2cc827d803159730b1da813a0c595969831.tar.gz kernel-f4c9c2cc827d803159730b1da813a0c595969831.zip | |
batman-adv: Fix incorrect offset in batadv_tt_tvlv_ogm_handler_v1()
Since commit 4436df478860 ("batman-adv: Add flex array to struct
batadv_tvlv_tt_data"), the introduction of batadv_tvlv_tt_data's flex
array member in batadv_tt_tvlv_ogm_handler_v1() put tt_changes at
invalid offset. Those TT changes are supposed to be filled from the end
of batadv_tvlv_tt_data structure (including vlan_data flexible array),
but only the flex array size is taken into account missing completely
the size of the fixed part of the structure itself.
Fix the tt_change offset computation by using struct_size() instead of
flex_array_size() so both flex array member and its container structure
sizes are taken into account.
Cc: [email protected]
Fixes: 4436df478860 ("batman-adv: Add flex array to struct batadv_tvlv_tt_data")
Signed-off-by: Remi Pommarel <[email protected]>
Signed-off-by: Sven Eckelmann <[email protected]>
Signed-off-by: Simon Wunderlich <[email protected]>
Diffstat (limited to 'scripts/rustdoc_test_gen.rs')
0 files changed, 0 insertions, 0 deletions
