1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:18:11 +00:00

Shell: Eliminate reference leak in AST::Execute::run()

This commit is contained in:
AnotherTest 2020-08-12 01:10:20 +04:30 committed by Andreas Kling
parent ab3e787334
commit 1dc5574245

View file

@ -889,7 +889,7 @@ RefPtr<Value> Execute::run(RefPtr<Shell> shell)
}
auto& last_in_commands = commands.last();
last_in_commands.redirections.prepend(*new FdRedirection(STDOUT_FILENO, pipefd[1], Rewiring::Close::Destination));
last_in_commands.redirections.prepend(adopt(*new FdRedirection(STDOUT_FILENO, pipefd[1], Rewiring::Close::Destination)));
last_in_commands.should_wait = true;
last_in_commands.should_notify_if_in_background = false;
last_in_commands.is_pipe_source = false;