aboutsummaryrefslogtreecommitdiff
path: root/libbb/bb_getgroups.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2024-10-09 13:01:28 +0100
committerRon Yorston <rmy@pobox.com>2024-10-09 13:01:28 +0100
commitc052d1180ec8a9d94a7bd6a64dd7b986ad1a5104 (patch)
tree803dea78f2846e1686a3f7357e828422bc918c79 /libbb/bb_getgroups.c
parent9b181bf263b9d7c71b347542d945fe2467a495c6 (diff)
downloadbusybox-w32-c052d1180ec8a9d94a7bd6a64dd7b986ad1a5104.tar.gz
busybox-w32-c052d1180ec8a9d94a7bd6a64dd7b986ad1a5104.tar.bz2
busybox-w32-c052d1180ec8a9d94a7bd6a64dd7b986ad1a5104.zip
id: code shrink
The bogus user/group ids we use on Windows are very limited. Make these limitations explicit in the 'id' applet. Saves 464 bytes.
Diffstat (limited to 'libbb/bb_getgroups.c')
-rw-r--r--libbb/bb_getgroups.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libbb/bb_getgroups.c b/libbb/bb_getgroups.c
index c255d4e4c..757b80be8 100644
--- a/libbb/bb_getgroups.c
+++ b/libbb/bb_getgroups.c
@@ -10,6 +10,7 @@
10 10
11#include "libbb.h" 11#include "libbb.h"
12 12
13#if !ENABLE_PLATFORM_MINGW32
13gid_t* FAST_FUNC bb_getgroups(int *ngroups, gid_t *group_array) 14gid_t* FAST_FUNC bb_getgroups(int *ngroups, gid_t *group_array)
14{ 15{
15 int n = ngroups ? *ngroups : 0; 16 int n = ngroups ? *ngroups : 0;
@@ -45,6 +46,7 @@ gid_t* FAST_FUNC bb_getgroups(int *ngroups, gid_t *group_array)
45 *ngroups = n; 46 *ngroups = n;
46 return group_array; 47 return group_array;
47} 48}
49#endif
48 50
49uid_t FAST_FUNC get_cached_euid(uid_t *euid) 51uid_t FAST_FUNC get_cached_euid(uid_t *euid)
50{ 52{