summaryrefslogtreecommitdiff
path: root/include/fstree.h
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-16 15:50:46 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-19 18:22:41 +0200
commitab0c4a02ba9d1a836f62a8601699c971b72eec07 (patch)
tree4ceb7a0a5d9c36189a05750da388941c8a223ebb /include/fstree.h
parent3f4f75777b9b558e0e8c4af4408b094b6d4b1034 (diff)
Add directory reader data structure
This moves a lot of the stuff that is done manually in the tree deserializer to a generic helper in libsquashfs. Due to how the fstree is implemented, as a work around, the inode needs to be temporarily stored in the tree node, but some of the directory details could be removed. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'include/fstree.h')
-rw-r--r--include/fstree.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/include/fstree.h b/include/fstree.h
index 4c02ce5..880a870 100644
--- a/include/fstree.h
+++ b/include/fstree.h
@@ -16,6 +16,8 @@
#include <stddef.h>
#include <stdio.h>
+#include "sqfs/inode.h"
+
#include "str_table.h"
#define FSTREE_XATTR_KEY_BUCKETS 31
@@ -105,12 +107,6 @@ struct dir_info_t {
directory meta data to disk. */
uint64_t size;
- /* Start block offset, relative to directory table start. */
- uint64_t start_block;
-
- /* Byte offset into the uncompressed meta data block. */
- uint32_t block_offset;
-
/* Set to true for implicitly generated directories. */
bool created_implicitly;
};
@@ -126,6 +122,8 @@ struct tree_node_t {
/* For the root node, this points to an empty string. */
char *name;
+ sqfs_inode_generic_t *inode;
+
/*
A pointer to an extended attribute array or NULL if unused.