Skip to content

Commit 02d8aaa

Browse files
kemzebADKaster
authored andcommitted
nohup: Use return code 127 for errors caught by serenity_main()
For any errors that occur during the runtime of nohup, POSIX uses a 127 return code.
1 parent 8bb459e commit 02d8aaa

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Userland/Utilities/nohup.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ void dup_out_file(int fd_to_redirect)
5454

5555
ErrorOr<int> serenity_main(Main::Arguments arguments)
5656
{
57+
Main::set_return_code_for_errors(127);
5758
TRY(Core::System::pledge("stdio wpath cpath rpath exec sigaction"));
5859

5960
StringView utility;

0 commit comments

Comments
 (0)