]> git.neil.brown.name Git - LaFS.git/commitdiff
Remove useless test in lafs_add_block_address
authorNeilBrown <neilb@suse.de>
Tue, 25 Aug 2009 07:09:52 +0000 (17:09 +1000)
committerNeilBrown <neilb@suse.de>
Tue, 25 Aug 2009 07:09:52 +0000 (17:09 +1000)
If it is an Index block, we never get to this test, so there is
no point testing it again.

index.c

diff --git a/index.c b/index.c
index c6e4a8133f979d2814ecae95f90192e4f097a5a9..64ea18c93017116384f19cd5541ac085cbd6f86a 100644 (file)
--- a/index.c
+++ b/index.c
@@ -1768,8 +1768,7 @@ int lafs_add_block_address(struct fs *fs, struct block *blk)
        spin_lock(&fs->lock);
        a = &p->uninc_table.pending_addr
                [p->uninc_table.pending_cnt-1];
-       if (!test_bit(B_Index, &blk->flags) &&
-           p->uninc_table.pending_cnt >= 1 &&
+       if (p->uninc_table.pending_cnt >= 1 &&
            a->fileaddr+a->cnt == blk->fileaddr &&
            a->physaddr+a->cnt == blk->physaddr) {
                a->cnt++;