LibCore: Print the actual errno if sysbeep failed

This commit is contained in:
Liav A 2022-01-22 12:38:55 +02:00 committed by Linus Groh
commit 24efc74318
Notes: sideshowbarker 2024-07-17 20:24:53 +09:00

View file

@ -46,7 +46,7 @@ ErrorOr<void> beep()
{
auto rc = ::sysbeep();
if (rc < 0)
return Error::from_syscall("beep", rc);
return Error::from_syscall("beep"sv, -errno);
return {};
}