Changeset 2f591127 in mainline for uspace/lib/ext4/libext4_ialloc.c


Ignore:
Timestamp:
2014-01-19T14:35:04Z (10 years ago)
Author:
Maurizio Lombardi <m.lombardi85@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5828554
Parents:
a159c6a
Message:

ext4: fix some minor bugs and memory leaks

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/ext4/libext4_ialloc.c

    ra159c6a r2f591127  
    204204                        rc = block_get(&bitmap_block, fs->device, bitmap_block_addr,
    205205                            BLOCK_FLAGS_NONE);
    206                         if (rc != EOK)
     206                        if (rc != EOK) {
     207                                ext4_filesystem_put_block_group_ref(bg_ref);
    207208                                return rc;
     209                        }
    208210                       
    209211                        /* Try to allocate i-node in the bitmap */
     
    225227                                        return rc;
    226228
     229                                bgid++;
    227230                                continue;
    228231                        }
     
    232235                       
    233236                        rc = block_put(bitmap_block);
    234                         if (rc != EOK)
     237                        if (rc != EOK) {
     238                                ext4_filesystem_put_block_group_ref(bg_ref);
    235239                                return rc;
     240                        }
    236241                       
    237242                        /* Modify filesystem counters */
Note: See TracChangeset for help on using the changeset viewer.