1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-28 10:37:44 +00:00

LibCore: Propagate errors from LibCore::Account::login()

This commit is contained in:
Lucas CHOLLET 2022-07-09 14:53:04 +02:00 committed by Sam Atkins
parent 08dcc40aa5
commit 8fabe9a3ad
4 changed files with 9 additions and 17 deletions

View file

@ -23,8 +23,8 @@ static void child_process(Core::Account const& account)
exit(1);
}
if (!account.login()) {
dbgln("failed to switch users: {}", strerror(errno));
if (auto const result = account.login(); result.is_error()) {
dbgln("failed to switch users: {}", result.error());
exit(1);
}