* [PATCH] e2fsprogs: remove redundant last-group check after ext2fs_group_last_block2
@ 2011-07-20 21:49 Eric Sandeen
2011-09-16 13:33 ` Ted Ts'o
0 siblings, 1 reply; 2+ messages in thread
From: Eric Sandeen @ 2011-07-20 21:49 UTC (permalink / raw)
To: ext4 development
ext2fs_group_last_block2() already properly calculates
the last block in the last group, so there is no need
to special-case this after the call.
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
---
diff --git a/lib/ext2fs/check_desc.c b/lib/ext2fs/check_desc.c
index 7929cd9..7b68af4 100644
--- a/lib/ext2fs/check_desc.c
+++ b/lib/ext2fs/check_desc.c
@@ -53,8 +53,6 @@ errcode_t ext2fs_check_desc(ext2_filsys fs)
EXT4_FEATURE_INCOMPAT_FLEX_BG)) {
first_block = ext2fs_group_first_block2(fs, i);
last_block = ext2fs_group_last_block2(fs, i);
- if (i == (fs->group_desc_count - 1))
- last_block = ext2fs_blocks_count(fs->super)-1;
}
/*
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: e2fsprogs: remove redundant last-group check after ext2fs_group_last_block2
2011-07-20 21:49 [PATCH] e2fsprogs: remove redundant last-group check after ext2fs_group_last_block2 Eric Sandeen
@ 2011-09-16 13:33 ` Ted Ts'o
0 siblings, 0 replies; 2+ messages in thread
From: Ted Ts'o @ 2011-09-16 13:33 UTC (permalink / raw)
To: Eric Sandeen; +Cc: ext4 development
On Wed, Jul 20, 2011 at 11:49:59AM -0000, Eric Sandeen wrote:
> ext2fs_group_last_block2() already properly calculates
> the last block in the last group, so there is no need
> to special-case this after the call.
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Applied with a slightly modified summary line:
libext2fs: remove redundant last-group check in ext2fs_check_desc()
- Ted
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-09-16 13:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-20 21:49 [PATCH] e2fsprogs: remove redundant last-group check after ext2fs_group_last_block2 Eric Sandeen
2011-09-16 13:33 ` Ted Ts'o
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).