X-Git-Url: https://wimlib.net/git/?a=blobdiff_plain;f=src%2Fwim.c;h=89b0156c82e1d5365d2cc6b564563c7fed116c47;hb=1530b6dab02a9e1e5faf81529ab502aee68d8cd2;hp=af5098cb2f4f6af17b4aeeba4e20fc5d85fe8cbf;hpb=fea0ee9f10fbcb85ff56ca06510e96186a7611ae;p=wimlib diff --git a/src/wim.c b/src/wim.c index af5098cb..89b0156c 100644 --- a/src/wim.c +++ b/src/wim.c @@ -1,5 +1,5 @@ /* - * wim.c + * wim.c - Stuff that doesn't fit into any other file */ /* @@ -43,13 +43,7 @@ #include "lookup_table.h" #include "xml.h" -static inline struct image_metadata * -wim_get_current_image_metadata(WIMStruct *w) -{ - return &w->image_metadata[w->current_image - 1]; -} - -static int print_metadata(WIMStruct *w) +static int image_print_metadata(WIMStruct *w) { DEBUG("Printing metadata for image %d", w->current_image); print_security_data(wim_security_data(w)); @@ -58,7 +52,7 @@ static int print_metadata(WIMStruct *w) } -static int print_files(WIMStruct *w) +static int image_print_files(WIMStruct *w) { return for_dentry_in_tree(wim_root_dentry(w), print_dentry_full_path, NULL); @@ -129,7 +123,7 @@ static int sort_image_metadata_by_position(const void *p1, const void *p2) * If @lte points to a metadata resource, append it to the list of metadata * resources in the WIMStruct. Otherwise, do nothing. */ -static int append_metadata_resource_entry(struct lookup_table_entry *lte, +static int append_metadata_resource_entry(struct wim_lookup_table_entry *lte, void *wim_p) { WIMStruct *w = wim_p; @@ -174,7 +168,7 @@ static int wim_hdr_flags_compression_type(int wim_hdr_flags) WIMLIBAPI int wimlib_create_new_wim(int ctype, WIMStruct **w_ret) { WIMStruct *w; - struct lookup_table *table; + struct wim_lookup_table *table; int ret; DEBUG("Creating new WIM with %s compression.", @@ -374,7 +368,7 @@ WIMLIBAPI int wimlib_print_metadata(WIMStruct *w, int image) ERROR("Select the first part of the split WIM to see the metadata."); return WIMLIB_ERR_SPLIT_UNSUPPORTED; } - return for_image(w, image, print_metadata); + return for_image(w, image, image_print_metadata); } WIMLIBAPI int wimlib_print_files(WIMStruct *w, int image) @@ -385,7 +379,7 @@ WIMLIBAPI int wimlib_print_files(WIMStruct *w, int image) ERROR("Select the first part of the split WIM if you'd like to list the files."); return WIMLIB_ERR_SPLIT_UNSUPPORTED; } - return for_image(w, image, print_files); + return for_image(w, image, image_print_files); } /* Sets the index of the bootable image. */ @@ -586,7 +580,7 @@ WIMLIBAPI int wimlib_open_wim(const char *wim_file, int open_flags, } void destroy_image_metadata(struct image_metadata *imd, - struct lookup_table *table) + struct wim_lookup_table *table) { free_dentry_tree(imd->root_dentry, table); free_security_data(imd->security_data);