Use ARRAY_SIZE() macro
Replace the common sizeof(a)/sizeof(a[0]) constructions with a more readable version. Signed-hostap: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
39044a7033
commit
e7ecab4a3b
22 changed files with 51 additions and 56 deletions
|
@ -268,7 +268,7 @@ int os_program_init(void)
|
|||
struct __user_cap_header_struct header;
|
||||
struct __user_cap_data_struct cap;
|
||||
|
||||
setgroups(sizeof(groups)/sizeof(groups[0]), groups);
|
||||
setgroups(ARRAY_SIZE(groups), groups);
|
||||
|
||||
prctl(PR_SET_KEEPCAPS, 1, 0, 0, 0);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue