Comment Comment by zyztem You might find source of Xv6 - educational version of unix - useful. Here is their implementation of cat, all 44 lines of it: https://github.com/mit-pdos/xv6-public/blob/master/cat.c parent zyztem 7 years ago