lstat: fix Solaris 9 bug
authorEric Blake <ebb9@byu.net>
Thu, 17 Sep 2009 21:55:24 +0000 (15:55 -0600)
committerEric Blake <ebb9@byu.net>
Sat, 19 Sep 2009 19:22:28 +0000 (13:22 -0600)
commitb4caad347f49b6fc8ec0b656e494dcd90f031b7c
tree8ef4226610ad283a5082956951772663eb712738
parentba1652925190702bec29e2c5129ee857576853d6
lstat: fix Solaris 9 bug

lstat("file/",buf) mistakenly succeeded.

* lib/lstat.c (lstat): Also check for trailing slash on
non-symlink, non-directories.  Use stat module to simplify logic.
* doc/posix-functions/lstat.texi (lstat): Document it.
* modules/lstat-tests (Depends-on): Add errno, same-inode.
(configure.ac): Check for symlink.
* tests/test-lstat.c (main): Add more tests.

Signed-off-by: Eric Blake <ebb9@byu.net>
ChangeLog
doc/posix-functions/lstat.texi
lib/lstat.c
modules/lstat-tests
tests/test-lstat.c