4 ms·
Finger basically just reads that file so if it’s a named pipe you can have a process generate content on the fly.
by burke 7y ago
Finger basically just reads that file so if it’s a named pipe you can have a process generate content on the fly.
- brianpgordon 7y agoHow does the process know that you're reading the pipe? Does it just, like, write a hundred copies of the desired output with EOFs in between so that it can be read multiple times?
- alt219 7y agoThe process writing to the pipe just blocks until another process starts reading from said pipe.
- brianpgordon 7y agoAh, right, I was misremembering how FIFOs work. You can't even write to it until a reader opens it. I was thinking that you could just dump data on it and the operating system would buffer it until someone came along to read it.