+ /* Test behaviour for invalid file descriptors. */
+ {
+ errno = 0;
+ ASSERT (readlinkat (-1, "foo", buf, sizeof buf) == -1);
+ ASSERT (errno == EBADF);
+ }
+ {
+ close (99);
+ errno = 0;
+ ASSERT (readlinkat (99, "foo", buf, sizeof buf) == -1);
+ ASSERT (errno == EBADF);
+ }
+