RenataKaras / minishell

0 stars 0 forks source link

several redirections one after the other #6

Open RenataKaras opened 9 hours ago

RenataKaras commented 9 hours ago

cat Makefile > out > out1 > out2 gives out:

cat: out2: input file is output file

even though it works correctly - it creates all the out files, and out and out 1 are empty.

RenataKaras commented 7 hours ago

Node Type: CMD Args: cat Makefile out out1 out2 IO Redirections: IO Type: Output Redirection (> or >>) IO Value: out IO Type: Output Redirection (> or >>) IO Value: out1 IO Type: Output Redirection (> or >>) IO Value: out2 IO Type: Output Redirection (> or >>) IO Value: out1 IO Type: Output Redirection (> or >>) IO Value: out2 IO Type: Output Redirection (> or >>) IO Value: out2

this is how the AST looks like, so this might be parsing mistake, becase I don't know why it's showing 6 IO nodes