mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 08:48:11 +00:00
Shell: Make Command::redirections a NonnullRefPtrVector
This commit is contained in:
parent
c29681cb03
commit
3b3d158649
2 changed files with 2 additions and 2 deletions
|
@ -152,7 +152,7 @@ private:
|
||||||
|
|
||||||
struct Command {
|
struct Command {
|
||||||
Vector<String> argv;
|
Vector<String> argv;
|
||||||
Vector<NonnullRefPtr<Redirection>> redirections;
|
NonnullRefPtrVector<Redirection> redirections;
|
||||||
bool should_wait { true };
|
bool should_wait { true };
|
||||||
bool is_pipe_source { false };
|
bool is_pipe_source { false };
|
||||||
bool should_notify_if_in_background { true };
|
bool should_notify_if_in_background { true };
|
||||||
|
|
|
@ -449,7 +449,7 @@ RefPtr<Job> Shell::run_command(const AST::Command& command)
|
||||||
// Resolve redirections.
|
// Resolve redirections.
|
||||||
NonnullRefPtrVector<AST::Rewiring> rewirings;
|
NonnullRefPtrVector<AST::Rewiring> rewirings;
|
||||||
for (auto& redirection : command.redirections) {
|
for (auto& redirection : command.redirections) {
|
||||||
auto rewiring_result = redirection->apply();
|
auto rewiring_result = redirection.apply();
|
||||||
if (rewiring_result.is_error()) {
|
if (rewiring_result.is_error()) {
|
||||||
if (!rewiring_result.error().is_empty())
|
if (!rewiring_result.error().is_empty())
|
||||||
fprintf(stderr, "error: %s\n", rewiring_result.error().characters());
|
fprintf(stderr, "error: %s\n", rewiring_result.error().characters());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue