[TUHS] fstat(2) on pipes?

Noel Chiappa jnc at mercury.lcs.mit.edu
Mon Aug 15 10:27:11 AEST 2016


    > From: Warren Toomey

    > I'm trying to find out what fstat(2) returns when the file descriptor
    > is a pipe.

In V6, it returns information about the file (inode) used as a temporary
storage area for data which has been written into the pipe, but not yet read;
i.e. it's an un-named file with a length which varies between 0 and 4KB.

    > xv6 has fstat() but returns an error if the file descriptor isn't
    > associated with an i-node.

?? All pipe file descriptors should have an inode?

	Noel


More information about the TUHS mailing list