Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/ext4/src/filesystem.c

    r7bdedb5 r6ba36a0  
    421421    enum cache_mode cmode, aoff64_t *size, ext4_filesystem_t **rfs)
    422422{
    423         int fs_inited = 0;
    424423        ext4_filesystem_t *fs = NULL;
    425424        fs_node_t *root_node = NULL;
     
    438437        if (rc != EOK)
    439438                goto error;
    440 
    441         fs_inited = 1;
    442439
    443440        /* Read root node */
     
    466463                ext4_node_put(root_node);
    467464
    468         if (fs_inited)
     465        if (fs != NULL) {
    469466                ext4_filesystem_fini(fs);
    470         free(fs);
     467                free(fs);
     468        }
     469
    471470        return rc;
    472471}
     
    715714                /* One for block bitmap one for inode bitmap */
    716715                free_blocks = free_blocks - reserved - 2 - inode_table_blocks;
     716                if (bg_index == 0)
     717                        ++free_blocks; /* XXX Why? */
    717718
    718719                ext4_block_group_set_free_blocks_count(bg_ref->block_group,
Note: See TracChangeset for help on using the changeset viewer.