printf("Full Path (UTF-8) = \"%s\"\n", dentry->full_path_utf8);
lte = inode_stream_lte(dentry->d_inode, 0, lookup_table);
if (lte) {
- print_lookup_table_entry(lte);
+ print_lookup_table_entry(lte, stdout);
} else {
hash = inode_stream_hash(inode, 0);
if (hash) {
print_hash(hash);
putchar('\n');
}
- print_lookup_table_entry(inode_stream_lte(inode, i + 1,
- lookup_table));
+ print_lookup_table_entry(inode_stream_lte(inode, i + 1, lookup_table),
+ stdout);
}
return 0;
}
destroy_ads_entry(ads_entry);
- memcpy(&inode->i_ads_entries[idx],
- &inode->i_ads_entries[idx + 1],
- (inode->i_num_ads - idx - 1) * sizeof(inode->i_ads_entries[0]));
+ memmove(&inode->i_ads_entries[idx],
+ &inode->i_ads_entries[idx + 1],
+ (inode->i_num_ads - idx - 1) * sizeof(inode->i_ads_entries[0]));
inode->i_num_ads--;
}
#endif
* u64 reserved1; (always 0)
* u64 reserved2; (always 0)
* };*/
- DEBUG("Dentry for file or directory `%s' has %zu extra "
+ DEBUG("Dentry for file or directory `%s' has %"PRIu64" extra "
"bytes of data",
file_name_utf8, dentry->length - calculated_size);
}
* recursively writing the directory trees rooted at each of the child
* dentries, since the on-disk dentries for a dentry's children are
* always located at consecutive positions in the metadata resource! */
- for_dentry_in_rbtree(parent->d_inode->i_children.rb_node, write_dentry_cb, &p);
+ for_dentry_child(parent, write_dentry_cb, &p);
/* write end of directory entry */
p = put_u64(p, 0);
/* Recurse on children. */
- for_dentry_in_rbtree(parent->d_inode->i_children.rb_node,
- write_dentry_tree_recursive_cb, &p);
+ for_dentry_child(parent, write_dentry_tree_recursive_cb, &p);
return p;
}