Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/ext2/libext2_directory.c

    r260c052 r18626b3  
    4545 * @param de pointer to linked list directory entry
    4646 */
    47 inline uint32_t ext2_directory_entry_ll_get_inode(ext2_directory_entry_ll_t *de)
     47uint32_t ext2_directory_entry_ll_get_inode(ext2_directory_entry_ll_t *de)
    4848{
    4949        return uint32_t_le2host(de->inode);
     
    5555 * @param de pointer to linked list directory entry
    5656 */
    57 inline uint16_t ext2_directory_entry_ll_get_entry_length(
     57uint16_t ext2_directory_entry_ll_get_entry_length(
    5858    ext2_directory_entry_ll_t *de)
    5959{
     
    6666 * @param de pointer to linked list directory entry
    6767 */
    68 inline uint16_t ext2_directory_entry_ll_get_name_length(
     68uint16_t ext2_directory_entry_ll_get_name_length(
    6969    ext2_superblock_t *sb, ext2_directory_entry_ll_t *de)
    7070{
     
    9393        it->fs = fs;
    9494       
    95         /* Get the first data block, so we can get the first entry */
     95        // Get the first data block, so we can get first entry
    9696        rc = ext2_filesystem_get_inode_data_block_index(fs, inode_ref->inode, 0,
    9797            &block_id);
     
    133133        size = ext2_inode_get_size(it->fs->superblock, it->inode_ref->inode);
    134134       
    135         /* Are we at the end? */
     135        // Are we at the end?
    136136        if (it->current_offset + skip >= size) {
    137137                rc = block_put(it->current_block);
     
    150150        next_block_idx = (it->current_offset + skip) / block_size;
    151151       
    152         /* If we are moving accross block boundary,
    153          * we need to get another block
    154          */
     152        // If we are moving accross block boundary,
     153        // we need to get another block
    155154        if (current_block_idx != next_block_idx) {
    156155                rc = block_put(it->current_block);
     
    177176        offset_in_block = (it->current_offset + skip) % block_size;
    178177       
    179         /* Ensure proper alignment */
     178        // Ensure proper alignment
    180179        if ((offset_in_block % 4) != 0) {
    181180                it->current = NULL;
     
    183182        }
    184183       
    185         /* Ensure that the core of the entry does not overflow the block */
     184        // Ensure that the core of the entry does not overflow the block
    186185        if (offset_in_block > block_size - 8) {
    187186                it->current = NULL;
     
    192191        it->current_offset += skip;
    193192       
    194         /* Ensure that the whole entry does not overflow the block */
     193        // Ensure that the whole entry does not overflow the block
    195194        skip = ext2_directory_entry_ll_get_entry_length(it->current);
    196195        if (offset_in_block + skip > block_size) {
     
    199198        }
    200199       
    201         /* Ensure the name length is not too large */
     200        // Ensure the name length is not too large
    202201        if (ext2_directory_entry_ll_get_name_length(it->fs->superblock,
    203202            it->current) > skip-8) {
Note: See TracChangeset for help on using the changeset viewer.