Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!ncar!cruff From: cruff@ncar.ucar.edu (Craig Ruff) Newsgroups: comp.lang.perl Subject: Perl 4 pl 10 bug with file tests Message-ID: <11914@ncar.ucar.edu> Date: 24 Jun 91 19:21:06 GMT Reply-To: cruff@ncar.UCAR.EDU (Craig Ruff) Organization: Scientific Computing Division/NCAR, Boulder CO Lines: 16 When using the saved lstat information, the use of any non '-l' file test results in the loss of memory about which type of stat was performed. For example: $name = 'symbolic_link'; lstat($name) || die "could not lstat $name: $!\n"; print "dir\n" if (-d _); print "symlink\n" if (-l _); gives this as an error: The stat preceding -l _ wasn't an lstat at t.pl line 5. -- Craig Ruff NCAR cruff@ncar.ucar.edu (303) 497-1211 P.O. Box 3000 Boulder, CO 80307