Skip to contentSkip to conversation

e2fsprogs: reprot minimal resize size when given size is too small

PATCH RESEND In review Josef Bacik 2 participants 2 messages Mar 13, 2008

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 e2fsprogs: reprot minimal resize size when given size is too small

Hello,

This is a resend of a patch I sent a few months ago that hasn't gotten picked up yet. This will spit out the correctly calculated minimal number of blocks the given fs can be resized to if the given resize size is too small. This is useful for creating images, you can do the install and then resize the image to the smallest possible size. Thank you,

Josef

resize/main.c +0 -5
index 7c1d0c1..a9653ee 100644
@@ -342,11 +342,6 @@ int main (int argc, char ** argv)
 	if (new_size_str) {
 		new_size = parse_num_blocks(new_size_str, 
 					    fs->super->s_log_block_size);
-		if (!new_size) {
-			com_err(program_name, 0, _("bad filesystem size - %s"),
-				new_size_str);
-			exit(1);
-		}
 	} else {
 		new_size = max_size;
 		/* Round down to an even multiple of a pagesize */
resize/resize2fs.c +148 -1

175 lines not on this page · raw message

#1 lore raw
Quoted 8 lines · Josef Bacik

Hello,

This is a resend of a patch I sent a few months ago that hasn't gotten picked up yet. This will spit out the correctly calculated minimal number of blocks the given fs can be resized to if the given resize size is too small. This is useful for creating images, you can do the install and then resize the image to the smallest possible size. Thank you,

Can you resend one with a Signed-off-by, please? (Or give me permission to add a "Signed-off-by: Josef Bacik <[email protected]>" line.)

Thanks!!

- Ted