Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected Execution Time Discrepancy in Test Case "./pipex infile 'sleep 3' 'sleep 1' outfile" #1

Open
Memli-Sheremeti opened this issue Jan 11, 2024 · 1 comment

Comments

@Memli-Sheremeti
Copy link

The current implementation of the pipex project exhibits unexpected behavior.
In the test case :

time ./pipex infile "'sleep 3" "sleep 1" outfile


bash :
input : time < infile sleep 3 | sleep 1 > outfile

According to the expected behavior specified by Bash, the execution should take a total of 3 seconds, corresponding to the longest duration among the given commands, rather than the sum of both durations (4 seconds).

@SuperiChili
Copy link

time ./pipex infile "sleep 2" "sleep 1" outfile
./pipex infile "sleep 2" "sleep 1" outfile 0.00s user 0.00s system 0% cpu 1.009 total

the program is taking 1 sec instead should take the higher value from sleep.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants