aboutsummaryrefslogtreecommitdiff
path: root/resize
diff options
context:
space:
mode:
authorTheodore Ts'o <tytso@mit.edu>2016-10-25 13:18:14 -0400
committerTheodore Ts'o <tytso@mit.edu>2016-10-25 13:18:14 -0400
commit1e19b01be31fc5264a84d246023ecf29e44949df (patch)
tree1e79cda08b03692caac51a4e82101fb806398603 /resize
parent05e7f37a4a7703435f589b50222bf67615a1788c (diff)
downloade2fsprogs-1e19b01be31fc5264a84d246023ecf29e44949df.tar.gz
resize2fs: fix resizing large file systems when block size != page size
Reported by: Jerry Lee <jerrylee@qnap.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'resize')
-rw-r--r--resize/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/resize/main.c b/resize/main.c
index 5a99483c..396391b6 100644
--- a/resize/main.c
+++ b/resize/main.c
@@ -505,7 +505,7 @@ int main (int argc, char ** argv)
new_size = max_size;
/* Round down to an even multiple of a pagesize */
if (sys_page_size > blocksize)
- new_size &= ~((sys_page_size / blocksize)-1);
+ new_size &= ~((blk64_t)((sys_page_size / blocksize)-1));
}
/* If changing 64bit, don't change the filesystem size. */
if (flags & (RESIZE_DISABLE_64BIT | RESIZE_ENABLE_64BIT)) {