Rendered at 18:15:19 GMT+0000 (Coordinated Universal Time) with Cloudflare Workers.
syncsynchalt 1 hours ago [-]
> If we pipe seq to less and look at the list of running processes using ps aux, we can see that the seq program is not running. ... This explains why the seq program is killed when it is piped to less.
This explanation isn't correct, since a running `less` would not close the pipe and is still a reader. Writes to the pipe would block until `less` fully consumed it, or until `less` was quit such as with the `q` command.
The text _is_ correct if you add a missing step to `q`uit out of the `less` program. I think this step must have been dropped along the way. Unfortunately the screen capture doesn't show this step either.
brabel 22 minutes ago [-]
Wouldn’t the seq process keep writing to output until the output buffer of the pipe got full and then the next write would block and seq would just pause waiting for the write call to unblock? Or my understanding of piping is incorrect?
This explanation isn't correct, since a running `less` would not close the pipe and is still a reader. Writes to the pipe would block until `less` fully consumed it, or until `less` was quit such as with the `q` command.
The text _is_ correct if you add a missing step to `q`uit out of the `less` program. I think this step must have been dropped along the way. Unfortunately the screen capture doesn't show this step either.