]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commit
libext2fs: set the fs block size to new_io in ext2fs_rewrite_to_io()
authorKit Westneat <kwestneat@ddn.com>
Mon, 2 Dec 2013 19:47:08 +0000 (14:47 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Mon, 2 Dec 2013 19:49:41 +0000 (14:49 -0500)
commit8b3c52fb8115c8c37835d74455619f380acbc833
tree8fc3b8441395baa4e60fe9278c238cd71871cbfa
parent4c2ae57d38f60fa74ecd5bb681c8fb80fba59b6a
libext2fs: set the fs block size to new_io in ext2fs_rewrite_to_io()

e2image manually opens a new IO channel, and then sets the file system
to use this new IO channel via ext2fs_rewrite+to_io().  We need to
make sure the IO channel is set to the file system's block size to
avoid some nasty buffer overruns.

[ Modified by tytso to use io_channel_set_blksize() ]

Signed-off-by: Kit Westneat <kwestneat@ddn.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
lib/ext2fs/openfs.c