diff options
author | Rob Landley <rob@landley.net> | 2006-11-02 02:57:27 -0500 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2006-11-02 02:57:27 -0500 |
commit | fa98d0193aaacbc900fd77507e2490b00fe72ee9 (patch) | |
tree | 3e9c18a2fa5abb0cbf148dca23c529309bd24b83 /lib/lib.h | |
parent | 15bdc11ec8dd724cc07502d534a04084d226f132 (diff) | |
download | toybox-fa98d0193aaacbc900fd77507e2490b00fe72ee9.tar.gz |
Add xabspath(), is_file_type(), which_in_path(), and find_in_path().
Diffstat (limited to 'lib/lib.h')
-rw-r--r-- | lib/lib.h | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -15,6 +15,7 @@ void *xmalloc(size_t size); void *xzalloc(size_t size); void xrealloc(void **ptr, size_t size); void *xstrndup(char *s, size_t n); +void *xstrdup(char *s); char *xmsprintf(char *format, ...); void xexec(char **argv); int xopen(char *path, int flags, int mode); @@ -23,7 +24,10 @@ ssize_t reread(int fd, void *buf, size_t count); ssize_t readall(int fd, void *buf, size_t count); void xread(int fd, char *buf, size_t count); char *xgetcwd(void); -char *find_in_path(char *path, char *filename); +char *xabspath(char *path); +int is_file_type(char *path, int type); +char *which_in_path(char *filename); +char *find_in_path(char *path, char *filename, int type); void utoa_to_buf(unsigned n, char *buf, unsigned buflen); void itoa_to_buf(int n, char *buf, unsigned buflen); char *utoa(unsigned n); |