summaryrefslogtreecommitdiff
path: root/include/sqfs/dir.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sqfs/dir.h')
-rw-r--r--include/sqfs/dir.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/sqfs/dir.h b/include/sqfs/dir.h
index a1ca69c..6e47fef 100644
--- a/include/sqfs/dir.h
+++ b/include/sqfs/dir.h
@@ -9,6 +9,8 @@
#include "config.h"
+#include "sqfs/meta_reader.h"
+
#include <stdint.h>
#define SQFS_MAX_DIR_ENT 256
@@ -34,4 +36,11 @@ typedef struct {
uint8_t name[];
} sqfs_dir_index_t;
+/* Returns 0 on success. Internally prints to stderr on failure */
+int meta_reader_read_dir_header(meta_reader_t *m, sqfs_dir_header_t *hdr);
+
+/* Entry can be freed with a single free() call.
+ The function internally prints to stderr on failure */
+sqfs_dir_entry_t *meta_reader_read_dir_ent(meta_reader_t *m);
+
#endif /* SQFS_DIR_H */