From: Bruno Haible Date: Sat, 31 Jul 2010 10:23:44 +0000 (+0200) Subject: readlink: Relax test a bit. X-Git-Tag: v0.1~3976 X-Git-Url: http://erislabs.net/gitweb/?p=gnulib.git;a=commitdiff_plain;h=4f2ec69bf1dbf08065d2e248f4fcee2a52f52675 readlink: Relax test a bit. --- diff --git a/ChangeLog b/ChangeLog index 574a1a300..edd0b8c68 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,14 @@ 2010-07-31 Bruno Haible + readlink: Relax test a bit. + * tests/test-readlink.h (test_readlink): Allow different errno value + when readlink is called with a file name that ends in / and refers to + a file. + Suggested by Eric Blake. + Reported by Rainer Tammer. + +2010-07-31 Bruno Haible + copysign: Does not require -lm on glibc systems. * modules/copysign (configure.ac): Use gl_MATHFUNC, not gl_COMMON_DOUBLE_MATHFUNC. diff --git a/tests/test-readlink.h b/tests/test-readlink.h index 1e482dfe7..d96017503 100644 --- a/tests/test-readlink.h +++ b/tests/test-readlink.h @@ -51,7 +51,7 @@ test_readlink (ssize_t (*func) (char const *, char *, size_t), bool print) ASSERT (errno == EINVAL); errno = 0; ASSERT (func (BASE "file/", buf, sizeof buf) == -1); - ASSERT (errno == ENOTDIR); + ASSERT (errno == ENOTDIR || errno == EINVAL); /* AIX yields EINVAL */ /* Now test actual symlinks. */ if (symlink (BASE "dir", BASE "link"))