fs/squashfs: sqfs_read: remove buggy offset functionality 87/250887/1
authorRichard Genoud <richard.genoud@posteo.net>
Tue, 3 Nov 2020 11:11:24 +0000 (12:11 +0100)
committerJaehoon Chung <jh80.chung@samsung.com>
Tue, 5 Jan 2021 07:11:57 +0000 (16:11 +0900)
commitae1cf0863d7d6c95e49c50ea60ebcb1bf2c2e756
treee72a9fdebebb21cd89d8ad956b91539c15e31fab
parentbb5b6958ed7e67a6e8c53dcddb398a0a01bf19d2
fs/squashfs: sqfs_read: remove buggy offset functionality

offset is the offset in the file read, not the offset in the destination
buffer.
If the offset is not null, this will lead to a memory corruption.
So, for now, we are returning an error if the offset is used.

Signed-off-by: Richard Genoud <richard.genoud@posteo.net>
[jh80.chung: cherry picked from mainline commit 21b1b3bad58b50e5464b1bf016e7c96bf18ddb8d]
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Change-Id: Ie50645e5fcb2f06a21c8f88e16da9b0d1db35cca
fs/squashfs/sqfs.c