File types
Jim Balter
jim at segue.segue.com
Sat Jan 12 08:14:35 AEST 1991
In article <1991Jan10.130009.3973 at usenet.ins.cwru.edu> chet at po.CWRU.Edu writes:
>In article <127561 at linus.mitre.org> dean at snkoil.mitre.org (Dean Cookson) writes:
>Stat is what more uses. You could try opening the file for writing and
>checking to see if the open fails with errno == EISDIR, but I don't think
>that's any better, and it has to be less portable.
Open the file for reading and then do an fstat. That only does one nami,
instead of two for stat and open.
More information about the Comp.unix.questions
mailing list