diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/libbb.h | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/include/libbb.h b/include/libbb.h index a2b9a82b2..ece1c9d91 100644 --- a/include/libbb.h +++ b/include/libbb.h | |||
@@ -338,17 +338,20 @@ uint16_t xatou16(const char *numstr); | |||
338 | /* These parse entries in /etc/passwd and /etc/group. This is desirable | 338 | /* These parse entries in /etc/passwd and /etc/group. This is desirable |
339 | * for BusyBox since we want to avoid using the glibc NSS stuff, which | 339 | * for BusyBox since we want to avoid using the glibc NSS stuff, which |
340 | * increases target size and is often not needed on embedded systems. */ | 340 | * increases target size and is often not needed on embedded systems. */ |
341 | extern long bb_xgetpwnam(const char *name); | 341 | extern long xuname2uid(const char *name); |
342 | extern long bb_xgetgrnam(const char *name); | 342 | extern long xgroup2gid(const char *name); |
343 | /*extern char *bb_getug(char *buffer, char *idname, long id, int bufsize, char prefix);*/ | 343 | /* wrapper: allows string to contain numeric uid or gid */ |
344 | extern char *bb_getpwuid(char *name, long uid, int bufsize); | 344 | extern unsigned long get_ug_id(const char *s, long (*xname2id)(const char *)); |
345 | extern char *bb_getgrgid(char *group, long gid, int bufsize); | 345 | /* from chpst. Does not die, returns 0 on failure */ |
346 | /* from chpst */ | ||
347 | struct bb_uidgid_t { | 346 | struct bb_uidgid_t { |
348 | uid_t uid; | 347 | uid_t uid; |
349 | gid_t gid; | 348 | gid_t gid; |
350 | }; | 349 | }; |
351 | extern unsigned uidgid_get(struct bb_uidgid_t*, const char* /*, unsigned*/); | 350 | extern int get_uidgid(struct bb_uidgid_t*, const char*, int numeric_ok); |
351 | /* what is this? */ | ||
352 | /*extern char *bb_getug(char *buffer, char *idname, long id, int bufsize, char prefix);*/ | ||
353 | extern char *bb_getpwuid(char *name, long uid, int bufsize); | ||
354 | extern char *bb_getgrgid(char *group, long gid, int bufsize); | ||
352 | 355 | ||
353 | 356 | ||
354 | enum { BB_GETOPT_ERROR = 0x80000000 }; | 357 | enum { BB_GETOPT_ERROR = 0x80000000 }; |
@@ -484,7 +487,6 @@ extern void vfork_daemon_rexec(int nochdir, int noclose, | |||
484 | int argc, char **argv, char *foreground_opt); | 487 | int argc, char **argv, char *foreground_opt); |
485 | #endif | 488 | #endif |
486 | extern int get_terminal_width_height(int fd, int *width, int *height); | 489 | extern int get_terminal_width_height(int fd, int *width, int *height); |
487 | extern unsigned long get_ug_id(const char *s, long (*__bb_getxxnam)(const char *)); | ||
488 | 490 | ||
489 | int is_in_ino_dev_hashtable(const struct stat *statbuf, char **name); | 491 | int is_in_ino_dev_hashtable(const struct stat *statbuf, char **name); |
490 | void add_to_ino_dev_hashtable(const struct stat *statbuf, const char *name); | 492 | void add_to_ino_dev_hashtable(const struct stat *statbuf, const char *name); |