BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / commit / 2d05318728e0aa3fca502a2aeb1738773fffc98b / include

// Related

Nucleus

Barry Directory listing in VFS 2d05318 (3 years, 2 months ago)
diff --git a/include/nucleus/vfs.h b/include/nucleus/vfs.h
index 2ab824c..8dd295a 100644
--- a/include/nucleus/vfs.h
+++ b/include/nucleus/vfs.h
@@ -3,6 +3,7 @@
 
 #include <stddef.h>
 #include <sys/types.h>
+#include <dirent.h>
 #include <nucleus/object.h>
 #include <nucleus/memory.h>
 
@@ -87,6 +88,7 @@ struct FileOps {
 	size_t (*write)(File *, char *, size_t, off_t);
 	int (*open)(File *);
 	int (*ioctl)(File *, unsigned long, uintptr_t);
+	int (*readdir)(File *, struct dirent *, off_t);
 	void (*mmap)(File *, void *, size_t, off_t);
 };
 
@@ -122,6 +124,7 @@ int file_open(File *file);
 size_t file_read(File *file, char *buf, size_t count);
 size_t file_write(File *file, char *buf, size_t count);
 int file_ioctl(File *file, unsigned long request, uintptr_t arpg);
+int file_readdir(File *file, struct dirent *dent, off_t index);
 void file_mmap(File *file, void *addr, size_t len, off_t offset);
 /* Files namespace functions */
 File *get_file_by_fd(int fd);