Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!apple!motcsd!hpda!hpcuhb!hp-ses!hpbbn!hpbbse!bbausch From: bbausch@hpbbse.HP.COM (Bernd Bausch) Newsgroups: comp.unix.questions Subject: Re: How do I detect output redirection? Message-ID: <5370001@hpbbse.HP.COM> Date: 26 Jun 89 20:15:50 GMT References: <26942@beta.lanl.gov> Organization: HP Boeblingen, Germany Lines: 8 Try the fstat system call. It returns information about a file, given a file descriptor. If you want to see whether two files are identical, check their device and inode number. I don't know how this works under NFS, though. Bernd.