f2fs: truncate preallocated blocks in error case
authorJaegeuk Kim <jaegeuk@kernel.org>
Sat, 31 Mar 2018 00:58:13 +0000 (17:58 -0700)
committerJaegeuk Kim <jaegeuk@kernel.org>
Sun, 8 Apr 2018 11:14:46 +0000 (04:14 -0700)
commit7f05fb451696e5314e477b273a420d172b47c5cb
tree63fa28e6f70e05e0479133a4d3e54ad040e058ba
parenta0a9a51ecdd118ee4051341a79a258a6a28120a7
f2fs: truncate preallocated blocks in error case

If write is failed, we must deallocate the blocks that we couldn't write.

Cc: stable@vger.kernel.org
Reviewed-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fs/f2fs/file.c