Home
last modified time | relevance | path

Searched refs:nsupp_groups (Results 1 – 2 of 2) sorted by relevance

/external/minijail/examples/
Ddrop_privs.cpp35 int nsupp_groups = getgroups(0, NULL); in log_resugid() local
36 if (nsupp_groups < 0) { in log_resugid()
39 if (nsupp_groups == 0) { in log_resugid()
44 gid_t *list = (gid_t*)calloc((size_t)nsupp_groups, sizeof(gid_t)); in log_resugid()
45 nsupp_groups = getgroups(nsupp_groups, list); in log_resugid()
46 if (nsupp_groups < 0) { in log_resugid()
49 for (size_t i = 0; i < (size_t)nsupp_groups; i++) { in log_resugid()
/external/minijail/test/
Dlibminijail_test.cpp31 int nsupp_groups = getgroups(0, NULL); in getgroups_with_alloc() local
32 if (nsupp_groups < 0) { in getgroups_with_alloc()
36 if (nsupp_groups == 0) { in getgroups_with_alloc()
41 *plist = (gid_t*)calloc((size_t)nsupp_groups, sizeof(gid_t)); in getgroups_with_alloc()
42 nsupp_groups = getgroups(nsupp_groups, *plist); in getgroups_with_alloc()
43 if (nsupp_groups < 0) { in getgroups_with_alloc()
48 return nsupp_groups; in getgroups_with_alloc()
107 size_t nsupp_groups = getgroups_with_alloc(&list); in log_resugid() local
108 for (size_t i = 0; i < (size_t)nsupp_groups; i++) { in log_resugid()