diff options
Diffstat (limited to 'libbb/procps.c')
-rw-r--r-- | libbb/procps.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libbb/procps.c b/libbb/procps.c index fb4c32001..5833a1f0d 100644 --- a/libbb/procps.c +++ b/libbb/procps.c | |||
@@ -12,13 +12,13 @@ | |||
12 | #include "libbb.h" | 12 | #include "libbb.h" |
13 | 13 | ||
14 | 14 | ||
15 | typedef struct unsigned_to_name_map_t { | 15 | typedef struct id_to_name_map_t { |
16 | long id; | 16 | uid_t id; |
17 | char name[USERNAME_MAX_SIZE]; | 17 | char name[USERNAME_MAX_SIZE]; |
18 | } unsigned_to_name_map_t; | 18 | } id_to_name_map_t; |
19 | 19 | ||
20 | typedef struct cache_t { | 20 | typedef struct cache_t { |
21 | unsigned_to_name_map_t *cache; | 21 | id_to_name_map_t *cache; |
22 | int size; | 22 | int size; |
23 | } cache_t; | 23 | } cache_t; |
24 | 24 | ||
@@ -39,7 +39,7 @@ void FAST_FUNC clear_username_cache(void) | |||
39 | #if 0 /* more generic, but we don't need that yet */ | 39 | #if 0 /* more generic, but we don't need that yet */ |
40 | /* Returns -N-1 if not found. */ | 40 | /* Returns -N-1 if not found. */ |
41 | /* cp->cache[N] is allocated and must be filled in this case */ | 41 | /* cp->cache[N] is allocated and must be filled in this case */ |
42 | static int get_cached(cache_t *cp, unsigned id) | 42 | static int get_cached(cache_t *cp, uid_t id) |
43 | { | 43 | { |
44 | int i; | 44 | int i; |
45 | for (i = 0; i < cp->size; i++) | 45 | for (i = 0; i < cp->size; i++) |
@@ -52,8 +52,8 @@ static int get_cached(cache_t *cp, unsigned id) | |||
52 | } | 52 | } |
53 | #endif | 53 | #endif |
54 | 54 | ||
55 | static char* get_cached(cache_t *cp, long id, | 55 | static char* get_cached(cache_t *cp, uid_t id, |
56 | char* FAST_FUNC x2x_utoa(long id)) | 56 | char* FAST_FUNC x2x_utoa(uid_t id)) |
57 | { | 57 | { |
58 | int i; | 58 | int i; |
59 | for (i = 0; i < cp->size; i++) | 59 | for (i = 0; i < cp->size; i++) |