struct lookup_table_entry {
/* List of lookup table entries in this hash bucket */
- struct hlist_node hash_list;
+ union {
+ struct hlist_node hash_list;
+ struct list_head list;
+ };
/* Location and size of the stream in the WIM, whether it is compressed
* or not, and whether it's a metadata resource or not. This is an
table->num_entries--;
}
+extern struct lookup_table_entry *new_lookup_table_entry();
extern struct lookup_table_entry *
-lookup_table_decrement_refcnt(struct lookup_table* table, const u8 hash[]);
-
-#ifdef WITH_FUSE
-extern struct lookup_table_entry *
-lte_decrement_num_opened_fds(struct lookup_table_entry *lte,
- struct lookup_table *table);
-#endif
-
-extern struct lookup_table_entry *
-lte_decrement_refcnt(struct lookup_table_entry *lte,
- struct lookup_table *table);
-
-
-extern struct lookup_table_entry *new_lookup_table_entry();
+clone_lookup_table_entry(const struct lookup_table_entry *lte);
extern int for_lookup_table_entry(struct lookup_table *table,
int (*visitor)(struct lookup_table_entry *, void *),
struct lookup_table_entry **lte_ret,
u16 *stream_idx_ret);
+extern void lte_decrement_refcnt(struct lookup_table_entry *lte,
+ struct lookup_table *table);
+extern void lte_decrement_num_opened_fds(struct lookup_table_entry *lte,
+ struct lookup_table *table);
+
extern int lte_zero_out_refcnt(struct lookup_table_entry *entry, void *ignore);
extern int lte_zero_real_refcnt(struct lookup_table_entry *entry, void *ignore);
extern int lte_free_extracted_file(struct lookup_table_entry *lte, void *ignone);
extern void free_lookup_table_entry(struct lookup_table_entry *lte);
extern int dentry_resolve_ltes(struct dentry *dentry, void *__table);
+extern int dentry_unresolve_ltes(struct dentry *dentry, void *ignore);
/* Writes the lookup table to the output file. */
static inline int write_lookup_table(struct lookup_table *table, FILE *out)
static inline struct lookup_table_entry *
inode_stream_lte_unresolved(const struct inode *inode, unsigned stream_idx,
- const struct lookup_table *table)
+ const struct lookup_table *table)
{
wimlib_assert(!inode->resolved);
wimlib_assert(stream_idx <= inode->num_ads);