File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -17,14 +17,9 @@ KResultOr<FlatPtr> Process::sys$realpath(Userspace<const Syscall::SC_realpath_pa
17
17
REQUIRE_PROMISE (rpath);
18
18
auto params = TRY (copy_typed_from_user (user_params));
19
19
20
- auto path = get_syscall_path_argument (params.path );
21
- if (path.is_error ())
22
- return path.error ();
20
+ auto path = TRY (get_syscall_path_argument (params.path ));
21
+ auto custody = TRY (VirtualFileSystem::the ().resolve_path (path->view (), current_directory ()));
23
22
24
- auto custody_or_error = VirtualFileSystem::the ().resolve_path (path.value ()->view (), current_directory ());
25
- if (custody_or_error.is_error ())
26
- return custody_or_error.error ();
27
- auto & custody = custody_or_error.value ();
28
23
auto absolute_path = custody->try_create_absolute_path ();
29
24
if (!absolute_path)
30
25
return ENOMEM;
You can’t perform that action at this time.
0 commit comments