mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-23 01:32:14 -05:00
Kernel: fix assertion on readlink() syscall
The is_error() check on the KResultOr returned when reading the link target had a stray ! operator which causes link resolution to crash the kernel with an assertion error.
This commit is contained in:
parent
8ff4ebb589
commit
6137475c39
Notes:
sideshowbarker
2024-07-19 17:34:07 +09:00
Author: https://github.com/anpep Commit: https://github.com/SerenityOS/serenity/commit/6137475c39d Pull-request: https://github.com/SerenityOS/serenity/pull/2390
1 changed files with 1 additions and 1 deletions
|
@ -1944,7 +1944,7 @@ int Process::sys$readlink(const Syscall::SC_readlink_params* user_params)
|
|||
return -EINVAL;
|
||||
|
||||
auto contents = description->read_entire_file();
|
||||
if (!contents.is_error())
|
||||
if (contents.is_error())
|
||||
return contents.error();
|
||||
|
||||
auto link_target = String::copy(contents.value());
|
||||
|
|
Loading…
Reference in a new issue