/bin/shutdown: fixed bug, was returning non zero even on shutdown
success. Spotted by mcandre, thanks!
This commit is contained in:
@@ -183,9 +183,10 @@ main(int argc, char **argv)
|
||||
BRoster roster;
|
||||
BRoster::Private rosterPrivate(roster);
|
||||
status_t error = rosterPrivate.ShutDown(gReboot, askUser, !async);
|
||||
if (error != B_OK)
|
||||
if (error != B_OK) {
|
||||
fprintf(stderr, "Shutdown failed: %s\n", strerror(error));
|
||||
return 2;
|
||||
return 2;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user