diff options
Diffstat (limited to 'lib/libc/include')
-rw-r--r-- | lib/libc/include/ctype.h | 9 | ||||
-rw-r--r-- | lib/libc/include/unistd.h | 13 |
2 files changed, 22 insertions, 0 deletions
diff --git a/lib/libc/include/ctype.h b/lib/libc/include/ctype.h index 0ff9a43..2a827e3 100644 --- a/lib/libc/include/ctype.h +++ b/lib/libc/include/ctype.h @@ -36,6 +36,12 @@ __BEGIN_DECLS __always_inline static inline int +__isascii(int c) +{ + return c >= 0 && c <= 127; +} + +__always_inline static inline int __tolower(int c) { return c | 0x20; @@ -92,4 +98,7 @@ __END_DECLS /* Is a space? */ #define isspace(C) __isspace((C)) +/* Is ascii? */ +#define isascii(C) __isascii((C)) + #endif /* _CTYPE_H */ diff --git a/lib/libc/include/unistd.h b/lib/libc/include/unistd.h index 21206ad..40ebee2 100644 --- a/lib/libc/include/unistd.h +++ b/lib/libc/include/unistd.h @@ -53,15 +53,28 @@ int sethostname(const char *name, size_t size); uid_t getuid(void); char *getlogin(void); +char *getcwd(char *buf, size_t size); +char *getwd(char *pathname); + +int symlink(const char *target, const char *linkpath); +int synlinkat(const char *target, int newdirfd, const char *linkpath); + ssize_t read(int fd, void *buf, size_t count); ssize_t write(int fd, const void *buf, size_t count); int close(int fd); int access(const char *path, int mode); + off_t lseek(int fildes, off_t offset, int whence); +int unlinkat(int dirfd, const char *pathname, int flags); +int unlink(const char *path); + +int dup(int fd); +int dup2(int fd, int fd1); pid_t getpid(void); pid_t getppid(void); +pid_t fork(void); extern char *optarg; extern int optind, opterr, optopt; |