mirror of
https://github.com/RGBCube/serenity
synced 2025-05-22 17:25:07 +00:00
Shell: Do not treat the absence of an init script as an error
This commit is contained in:
parent
e83c36d053
commit
6d17fe38a4
3 changed files with 6 additions and 5 deletions
|
@ -499,11 +499,12 @@ RefPtr<Job> Shell::run_command(AST::Command& command)
|
|||
return *job;
|
||||
}
|
||||
|
||||
bool Shell::run_file(const String& filename)
|
||||
bool Shell::run_file(const String& filename, bool explicitly_invoked)
|
||||
{
|
||||
auto file_result = Core::File::open(filename, Core::File::ReadOnly);
|
||||
if (file_result.is_error()) {
|
||||
fprintf(stderr, "Failed to open %s: %s\n", filename.characters(), file_result.error().characters());
|
||||
if (explicitly_invoked)
|
||||
fprintf(stderr, "Failed to open %s: %s\n", filename.characters(), file_result.error().characters());
|
||||
return false;
|
||||
}
|
||||
auto file = file_result.value();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue