18#include <FreeNOS/User.h>
C size_t strlcpy(char *dst, const char *src, size_t siz)
Copy src to string dst of size siz.
#define DT_DIR
This is a directory.
#define DT_BLK
This is a block device.
C int open(const char *path, int oflag,...)
Open file relative to directory file descriptor.
C char * dirname(char *path)
Return the directory portion of a pathname.
#define ESUCCESS
Reports a success operation.
C int errno
The lvalue errno is used by many functions to return error values.
C void * memset(void *dest, int ch, size_t count)
Fill memory with a constant byte.
#define DT_FIFO
This is a named pipe (FIFO).
#define DT_CHR
This is a character device.
C ssize_t read(int fildes, void *buf, size_t nbyte)
Read from a file.
#define DT_REG
This is a regular file.
#define DIRLEN
Maximum length of a directory entry name.
#define DT_LNK
This is a symbolic link.
#define DT_SOCK
This is a Unix domain socket.
DIR * opendir(const char *dirname)
Open directory associated with file descriptor.
C int closedir(DIR *dirp)
Close a directory stream.
slong Error
Error code defined in Error.h.
unsigned int Size
Any sane size indicator cannot go negative.
unsigned char u8
Unsigned 8-bit number.
A type representing a directory stream.
Size count
Number of direct structures in the buffer.
bool eof
End-of-file reached?
struct dirent * buffer
Input buffer.
Size current
Index of the current dirent.
int fd
File descriptor returned by opendir().
Describes an entry inside a Directory.
Represents a directory entry.
The <sys/stat.h> header shall define the stat structure.