fs/ntfs3: One more reason to mark inode bad
BugLink: https://bugs.launchpad.net/bugs/2085849 [ Upstream commit a0dde5d7a58b6bf9184ef3d8c6e62275c3645584 ] In addition to returning an error, mark the node as bad. Signed-off-by: Konstantin Komarov <almaz.alexandrovich@paragon-software.com> Signed-off-by: Sasha Levin <sashal@kernel.org> Signed-off-by: Manuel Diewald <manuel.diewald@canonical.com> Signed-off-by: Roxana Nicolescu <roxana.nicolescu@canonical.com>
This commit is contained in:
committed by
Mehmet Basaran
parent
8564150d1e
commit
7bae641c86
+3
-1
@@ -1601,8 +1601,10 @@ int ni_delete_all(struct ntfs_inode *ni)
|
||||
asize = le32_to_cpu(attr->size);
|
||||
roff = le16_to_cpu(attr->nres.run_off);
|
||||
|
||||
if (roff > asize)
|
||||
if (roff > asize) {
|
||||
_ntfs_bad_inode(&ni->vfs_inode);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* run==1 means unpack and deallocate. */
|
||||
run_unpack_ex(RUN_DEALLOCATE, sbi, ni->mi.rno, svcn, evcn, svcn,
|
||||
|
||||
Reference in New Issue
Block a user