aboutsummaryrefslogtreecommitdiff
path: root/include/fs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/fs.h')
-rw-r--r--include/fs.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/include/fs.h b/include/fs.h
index 81acd92..0698871 100644
--- a/include/fs.h
+++ b/include/fs.h
@@ -11,11 +11,15 @@
#define SPM_FSTREE_FLT_RELATIVE 1 << 4
typedef struct {
+ char *name;
+ struct stat *st;
+} FSRec;
+
+typedef struct {
char *root;
- char **dirs;
- size_t dirs_length;
- char **files;
- size_t files_length;
+ FSRec **record;
+ size_t num_records;
+ size_t _num_alloc;
} FSTree;
typedef struct {
@@ -28,6 +32,7 @@ typedef struct {
int _fstree_compare(const FTSENT **a, const FTSENT **b);
FSTree *fstree(const char *_path, char **filter_by, unsigned int filter_mode);
void fstree_free(FSTree *fsdata);
+char *fstree_search(FSTree *fsdata, char *path);
FSList *fslist(const char *path);
void fslist_free(FSList *fsdata);
int exists(const char *filename);