useful-e2fsck-files/blknum.c
int ext2fs_group_blocks_count(ext2_filsys fs, dgrp_t group)
{
	int num_blocks;

	if (group == fs->group_desc_count - 1) {
		num_blocks = (ext2fs_blocks_count(fs->super) -
				fs->super->s_first_data_block) %
			      fs->super->s_blocks_per_group;
		if (!num_blocks)
			num_blocks = fs->super->s_blocks_per_group;
	} else
		num_blocks = fs->super->s_blocks_per_group;

	return num_blocks;
}
/*
 * Return the number of blocks in a group
 */
Return the number of blocks in a group
Return the number of blocks in a group
int ext2fs_group_blocks_count(ext2_filsys fs, dgrp_t group)
{
	int num_blocks;
	if (group == fs->group_desc_count - 1) {
		num_blocks = (ext2fs_blocks_count(fs->super) -
				fs->super->s_first_data_block) %
			      fs->super->s_blocks_per_group;
		if (!num_blocks)
			num_blocks = fs->super->s_blocks_per_group;
	} else
		num_blocks = fs->super->s_blocks_per_group;
	return num_blocks;
}
int ext2fs_group_blocks_count ( ext2_filsys fs , dgrp_t group ) { int num_blocks ; if ( group == fs -> group_desc_count - 1 ) { num_blocks = ( ext2fs_blocks_count ( fs -> super ) - fs -> super -> s_first_data_block ) % fs -> super -> s_blocks_per_group ; if ( ! num_blocks ) num_blocks = fs -> super -> s_blocks_per_group ; } else num_blocks = fs -> super -> s_blocks_per_group ; return num_blocks ; }
Return the number of blocks in a group
Return the number of blocks in a group