diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2020-10-15 09:28:58 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2020-10-15 09:50:12 +0200 |
| commit | 638690213ad14c862fe8eca5c0629eaca46749f8 (patch) | |
| tree | 46ab9454552342212a1502ce41b4148f60590ab7 /executor | |
| parent | a83184a9374f9e15abe09dd727d2c2d5c82e1349 (diff) | |
executor: fix arp netfiler tables alignment for arm
The arp netfilter entry contains u64,
but we used only void* to enforce alignment.
This worked everywhere except for arm,
which is 32-bits and has 8-byte alignment for u64.
Use u64 to enforce correct alignment.
Fixes #2188
Diffstat (limited to 'executor')
| -rw-r--r-- | executor/common_linux.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/executor/common_linux.h b/executor/common_linux.h index 146984b3b..76f75c316 100644 --- a/executor/common_linux.h +++ b/executor/common_linux.h @@ -2947,7 +2947,7 @@ struct ipt_getinfo { struct ipt_get_entries { char name[32]; unsigned int size; - void* entrytable[XT_TABLE_SIZE / sizeof(void*)]; + uint64 entrytable[XT_TABLE_SIZE / sizeof(uint64)]; }; struct ipt_replace { @@ -2959,7 +2959,7 @@ struct ipt_replace { unsigned int underflow[5]; unsigned int num_counters; struct xt_counters* counters; - char entrytable[XT_TABLE_SIZE]; + uint64 entrytable[XT_TABLE_SIZE / sizeof(uint64)]; }; struct ipt_table_desc { @@ -3001,7 +3001,7 @@ struct arpt_getinfo { struct arpt_get_entries { char name[32]; unsigned int size; - void* entrytable[XT_TABLE_SIZE / sizeof(void*)]; + uint64 entrytable[XT_TABLE_SIZE / sizeof(uint64)]; }; struct arpt_replace { @@ -3013,7 +3013,7 @@ struct arpt_replace { unsigned int underflow[3]; unsigned int num_counters; struct xt_counters* counters; - char entrytable[XT_TABLE_SIZE]; + uint64 entrytable[XT_TABLE_SIZE / sizeof(uint64)]; }; struct arpt_table_desc { |
