|
|
| laziness, impatience, and hubris | |
| PerlMonks |
Re^4: The basicsby Tanktalus (Canon) |
| on Jun 25, 2006 at 10:25 UTC ( [id://557432]=note: print w/replies, xml ) | Need Help?? |
This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.
I'm trying to figure out where you get the idea that the contents are passed to tail's stdin. It's not. The full path to the file (as given by the shell - full path if searched via PATH, relative path if PATH not used) is passed in. Compare the output of "strace ./a" and "strace /usr/bin/tail -n2 < a". The former has a call to "open" and all reading is done from filehandle 3. The latter doesn't call open, and all reading is done from filehandle 0.
In Section
Tutorials
|
|
||||||||||||||||||||||||||||