Changeset d9bbe45 in mainline for uspace/lib/ext4/libext4_directory.c
- Timestamp:
- 2012-01-22T13:22:56Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- fcae007
- Parents:
- b7e0260
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/ext4/libext4_directory.c
rb7e0260 rd9bbe45 125 125 int rc; 126 126 127 uint64_t size; 128 aoff64_t current_block_idx; 129 aoff64_t next_block_idx; 130 uint32_t next_block_phys_idx; 131 uint32_t block_size; 132 133 size = ext4_inode_get_size(it->fs->superblock, it->inode_ref->inode); 127 uint64_t size = ext4_inode_get_size(it->fs->superblock, it->inode_ref->inode); 134 128 135 129 /* The iterator is not valid until we seek to the desired position */ … … 150 144 } 151 145 152 block_size = ext4_superblock_get_block_size(it->fs->superblock);153 current_block_idx = it->current_offset / block_size;154 next_block_idx = pos / block_size;146 uint32_t block_size = ext4_superblock_get_block_size(it->fs->superblock); 147 aoff64_t current_block_idx = it->current_offset / block_size; 148 aoff64_t next_block_idx = pos / block_size; 155 149 156 150 /* If we don't have a block or are moving accross block boundary, … … 166 160 } 167 161 162 uint32_t next_block_phys_idx; 168 163 rc = ext4_filesystem_get_inode_data_block_index(it->fs, 169 164 it->inode_ref->inode, next_block_idx, &next_block_phys_idx); … … 188 183 uint32_t block_size) 189 184 { 185 186 it->current = NULL; 187 190 188 uint32_t offset_in_block = it->current_offset % block_size; 191 192 it->current = NULL;193 189 194 190 /* Ensure proper alignment */ … … 439 435 { 440 436 int rc; 441 ext4_directory_iterator_t it;442 437 443 438 if (!ext4_inode_is_type(fs->superblock, parent->inode, … … 446 441 } 447 442 443 ext4_directory_iterator_t it; 448 444 rc = ext4_directory_iterator_init(&it, fs, parent, 0); 449 445 if (rc != EOK) {
Note:
See TracChangeset
for help on using the changeset viewer.