Lines Matching refs:dirbuf
621 static int recurse_dir(int fd, struct ext4_inode *inode, char *dirbuf, int dirsize, int mode)
673 read_block(fd, block_list[i], dirbuf + (i * info.block_size));
676 dirp = (struct ext4_dir_entry_2 *)dirbuf;
677 while (dirp < (struct ext4_dir_entry_2 *)(dirbuf + dirsize)) {
679 leftover_space = (char *)(dirbuf + dirsize) - (char *)dirp;
770 write_block(fd, block_list[i], dirbuf + (i * info.block_size));
792 char *dirbuf;
846 dirbuf = malloc(dirsize);
847 if (dirbuf == 0) {
848 critical_error("failed to allocate memory for dirbuf\n");
864 recurse_dir(fd, &root_inode, dirbuf, dirsize, SANITY_CHECK_PASS);
874 if (!recurse_dir(fd, &root_inode, dirbuf, dirsize, MARK_INODE_NUMS)) {
881 if (!recurse_dir(fd, &root_inode, dirbuf, dirsize, UPDATE_INODE_NUMS)) {