readlink: fix Solaris 9 bug with trailing slash
authorEric Blake <ebb9@byu.net>
Tue, 22 Sep 2009 23:15:04 +0000 (17:15 -0600)
committerEric Blake <ebb9@byu.net>
Wed, 23 Sep 2009 11:39:19 +0000 (05:39 -0600)
readlink("link/",buf,len) mistakenly succeeded.

* lib/readlink.c (rpl_readlink): Work around trailing slash bug.
* m4/readlink.m4 (gl_FUNC_READLINK): Detect the bug.
* doc/posix-functions/readlink.texi (readlink): Document this.
* modules/readlink-tests: New test.
* tests/test-readlink.c: Likewise.

Signed-off-by: Eric Blake <ebb9@byu.net>

No differences found