This commit is contained in:
2026-03-30 11:42:28 +02:00
parent ad76ae2375
commit 2b72e47ba5
2 changed files with 73 additions and 3 deletions

View File

@@ -48,6 +48,8 @@ typedef enum ncl_VFSAction {
// non-recursively remove entry
NCL_VFS_REMOVE,
// non-recursively make directory
NCL_VFS_MKDIR,
NCL_VFS_STAT,
} ncl_VFSAction;
@@ -92,6 +94,7 @@ typedef struct ncl_VFSRequest {
} readdir;
void *closedir;
const char *remove;
const char *mkdir;
struct {
// set to NULL if missing
const char *path;
@@ -138,9 +141,14 @@ size_t ncl_spaceUsedIn(ncl_VFS vfs, const char *path);
// gets the real space used
size_t ncl_spaceUsedBy(ncl_VFS vfs, const char *path);
bool ncl_exists(ncl_VFS vfs, const char *path);
bool ncl_remove(ncl_VFS vfs, const char *path);
bool ncl_removeRecursive(ncl_VFS vfs, const char *path);
bool ncl_mkdir(ncl_VFS vfs, const char *path);
bool ncl_mkdirRecursive(ncl_VFS vfs, const char *path);
typedef struct ncl_EncodedState {
char *buf;
size_t len;