u64 offset1 = imd1->metadata_lte->resource_entry.offset;
u64 offset2 = imd2->metadata_lte->resource_entry.offset;
if (offset1 < offset2)
u64 offset1 = imd1->metadata_lte->resource_entry.offset;
u64 offset2 = imd2->metadata_lte->resource_entry.offset;
if (offset1 < offset2)
* If @lte points to a metadata resource, append it to the list of metadata
* resources in the WIMStruct. Otherwise, do nothing.
*/
* If @lte points to a metadata resource, append it to the list of metadata
* resources in the WIMStruct. Otherwise, do nothing.
*/
if (w->hdr.image_count != 0) {
w->image_metadata = CALLOC(w->hdr.image_count,
if (w->hdr.image_count != 0) {
w->image_metadata = CALLOC(w->hdr.image_count,
if (!w->image_metadata) {
ERROR("Failed to allocate memory for %u image metadata structures",
if (!w->image_metadata) {
ERROR("Failed to allocate memory for %u image metadata structures",
* file, rather than their order in the lookup table, which is random
* because of hashing. */
qsort(w->image_metadata, w->current_image,
* file, rather than their order in the lookup table, which is random
* because of hashing. */
qsort(w->image_metadata, w->current_image,
-void destroy_image_metadata(struct image_metadata *imd,
- struct lookup_table *table)
+void destroy_image_metadata(struct wim_image_metadata *imd,
+ struct wim_lookup_table *table)
{
free_dentry_tree(imd->root_dentry, table);
free_security_data(imd->security_data);
{
free_dentry_tree(imd->root_dentry, table);
free_security_data(imd->security_data);