mirror of https://github.com/vitalif/e2fsprogs
tune2fs: fix memory leak in inode_scan_and_fix()
When we use ext2fs_open_inode_scan() to iterate inodes and finish jobs, we also need a ext2fs_close_inode_scan(scan) operation, but in inode_scan_and_fix(), we forgot to call it, fix this error. Signed-off-by: Xiaoguang Wang <wangxg.fnst@cn.fujitsu.com> Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu>test-maint
parent
e68476935b
commit
5da8912008
|
@ -1603,6 +1603,7 @@ static int inode_scan_and_fix(ext2_filsys fs, ext2fs_block_bitmap bmap)
|
|||
|
||||
err_out:
|
||||
ext2fs_free_mem(&block_buf);
|
||||
ext2fs_close_inode_scan(scan);
|
||||
|
||||
return retval;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue