Closed biralavor closed 1 month ago
The actions result didn 't achieve the main goal:
0s
Run echo "Running Valgrind tests..."
Running Valgrind tests...
==3068== Memcheck, a memory error detector
==3068== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==3068== Using Valgrind-3.18.1 and LibVEX; rerun with -h for copyright info
==3068== Command: ./minishell
==3068==
<<< Born Again (mini) SHell >>>$ exit
==3068==
==3068== HEAP SUMMARY:
==3068== in use at exit: 194,727 bytes in 211 blocks
==3068== total heap usage: 994 allocs, 783 frees, 237,025 bytes allocated
==3068==
==3068== LEAK SUMMARY:
==3068== definitely lost: 0 bytes in 0 blocks
==3068== indirectly lost: 0 bytes in 0 blocks
==3068== possibly lost: 0 bytes in 0 blocks
==3068== still reachable: 0 bytes in 0 blocks
==3068== suppressed: 194,727 bytes in 211 blocks
==3068==
==3068== For lists of detected and suppressed errors, rerun with: -s
==3068== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
Testing: |
<<< Born Again (mini) SHell >>>$ | echo oi
syntax error near unexpected token `|'
<<< Born Again (mini) SHell >>>$ | |
<<< Born Again (mini) SHell >>>$ | $
syntax error near unexpected token `|'
syntax error near unexpected token `|'
syntax error near unexpected token `|'
syntax error near unexpected token `newline'
syntax error near unexpected token `newline'
syntax error near unexpected token `>'
syntax error near unexpected token `newline'
syntax error near unexpected token `newline'
<<< Born Again (mini) SHell >>>$ | >
<<< Born Again (mini) SHell >>>$ >
<<< Born Again (mini) SHell >>>$ >>
<<< Born Again (mini) SHell >>>$ >>>
<<< Born Again (mini) SHell >>>$ <
<<< Born Again (mini) SHell >>>$ <<
<<< Born Again (mini) SHell >>>$ echo hi <
syntax error near unexpected token `newline'
syntax error near unexpected token `|'
syntax error near unexpected token `newline'
syntax error near unexpected token `>>'
syntax error near unexpected token `|'
syntax error near unexpected token `|'
<<< Born Again (mini) SHell >>>$ cat <| ls
<<< Born Again (mini) SHell >>>$ echo hi | >
<<< Born Again (mini) SHell >>>$ echo hi | > >>
<<< Born Again (mini) SHell >>>$ echo hi | < |
<<< Born Again (mini) SHell >>>$ echo hi | |
<<< Born Again (mini) SHell >>>$ echo hi | "|"
|: command not found
<<< Born Again (mini) SHell >>>$ exit
------------------------
grep: valgrind-out.txt: No such file or directory
<<< Born Again (mini) SHell >>>$ exit
------------------------
grep: valgrind-out.txt: No such file or directory
I couldn't make a better result than this: