Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f59ff666 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Greg Kroah-Hartman
Browse files

reiserfs: Check the return value from __getblk()



[ Upstream commit ba38980add7ffc9e674ada5b4ded4e7d14e76581 ]

__getblk() can return a NULL pointer if we run out of memory or if we
try to access beyond the end of the device; check it and handle it
appropriately.

Signed-off-by: default avatarMatthew Wilcox (Oracle) <willy@infradead.org>
Link: https://lore.kernel.org/lkml/CAFcO6XOacq3hscbXevPQP7sXRoYFz34ZdKPYjmd6k5sZuhGFDw@mail.gmail.com/


Tested-by: default avatarbutt3rflyh4ck <butterflyhuangxx@gmail.com>
Fixes: 1da177e4 ("Linux-2.6.12-rc2") # probably introduced in 2002
Acked-by: default avatarEdward Shishkin <edward.shishkin@gmail.com>
Signed-off-by: default avatarChristian Brauner <brauner@kernel.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent e74903b5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment