fsck.f2fs: fix symlink correctly
authorChao Yu <yuchao0@huawei.com>
Mon, 12 Aug 2019 11:45:27 +0000 (19:45 +0800)
committerJaegeuk Kim <jaegeuk@kernel.org>
Tue, 27 Aug 2019 21:51:05 +0000 (14:51 -0700)
commit121f29b7b9f2bb71ba73ef10819ad6de8ba70eab
treed1f96df51a87a8b3823fb42e59767d4396068927
parent3ea1f0567db68794fe38e02e43d0da6a1b53d037
fsck.f2fs: fix symlink correctly

inode.i_blocks includes inode, xnode and data block count, so, only
fix in below condition:
- i_blocks := 3 (inode + xnode + data_block)
- i_blocks := 2 (inode + data_block)

In addition, it recovers symlink's i_size to 4k rather than i_blocks *
4k.

Signed-off-by: Chao Yu <yuchao0@huawei.com>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
fsck/fsck.c