Thanks (was: How to determine file being redirected to in C)
Roger A. Cornelius
rac at sherpa.UUCP
Thu Mar 2 13:13:56 AEST 1989
Just wanted to say thanks for all the replies I received to
my question about determining if output is being redirected
to a file, from within a C program. Basically everyone gave
me the same answer, that is to use stat or fstat.
I didn't need to know the name of the file being redirected
to as many people thought, only whether the input/output was
being redirected. From the replies I got, this is a good thing.
Thanks again,
Roger
--
Roger Cornelius rac at sherpa
uunet!sherpa!rac
More information about the Comp.unix.questions
mailing list