diff options
Diffstat (limited to 'sw-old/z80/kernel/include/fs/dirent.h')
-rw-r--r-- | sw-old/z80/kernel/include/fs/dirent.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sw-old/z80/kernel/include/fs/dirent.h b/sw-old/z80/kernel/include/fs/dirent.h new file mode 100644 index 0000000..2fd224a --- /dev/null +++ b/sw-old/z80/kernel/include/fs/dirent.h @@ -0,0 +1,17 @@ +#ifndef __DIRENT_H__ +#define __DIRENT_H__ + +#include "types.h" + +struct dirent +{ + ino_t inode; // inode referred + uint8_t name_size; // size of the name + char name[]; // name of the referred inode +}; + +/* if inode is FS_INO_NULL, then the dirent is a memory leak */ +/* Warning: dirent leaks are generated by rm or rmdir operations */ +/* Filesystem must be periodically checked and cleaned */ + +#endif // __DIRENT_H__ |