mirror of
https://github.com/RGBCube/serenity
synced 2025-07-24 19:07:35 +00:00
Kernel: Use TRY() in sys$dbgputstr()
This commit is contained in:
parent
6dddd500bf
commit
cf2c04eb13
1 changed files with 1 additions and 4 deletions
|
@ -38,10 +38,7 @@ KResultOr<FlatPtr> Process::sys$dbgputstr(Userspace<const char*> characters, siz
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
auto result = try_copy_kstring_from_user(characters, size);
|
auto string = TRY(try_copy_kstring_from_user(characters, size));
|
||||||
if (result.is_error())
|
|
||||||
return result.error();
|
|
||||||
auto string = result.release_value();
|
|
||||||
dbgputstr(string->view());
|
dbgputstr(string->view());
|
||||||
return string->length();
|
return string->length();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue