]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
* sysdeps/unix/sysv/linux/linkat.c (linkat): Allow flags to be set
authorUlrich Drepper <drepper@redhat.com>
Mon, 27 Feb 2006 21:45:10 +0000 (21:45 +0000)
committerUlrich Drepper <drepper@redhat.com>
Mon, 27 Feb 2006 21:45:10 +0000 (21:45 +0000)
when syscall is used.
* io/fcntl.h (AT_SYMLINK_FOLLOW): Define.

ChangeLog
sysdeps/unix/sysv/linux/linkat.c

index d7817a06570d0aefb541a8d94e8d5a19592606d2..dfdfbb7586516f96523f0e22a1f35b6147a6f61a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-02-27  Ulrich Drepper  <drepper@redhat.com>
+
+       * sysdeps/unix/sysv/linux/linkat.c (linkat): Allow flags to be set
+       when syscall is used.
+       * io/fcntl.h (AT_SYMLINK_FOLLOW): Define.
+
 2006-02-26  Roland McGrath  <roland@redhat.com>
 
        * sysdeps/unix/common/Makefile: File removed.
index e1faf9db56f0e9655c925271aa17b4a4d5d1bb48..cfd0e18223bdd35d9d5d05f0e6234de196147621 100644 (file)
@@ -37,13 +37,6 @@ linkat (fromfd, from, tofd, to, flags)
 {
   int result;
 
-  // XXX Will be removed once the kernel support is in place.
-  if (flags != 0)
-    {
-      __set_errno (EINVAL);
-      return -1;
-    }
-
 #ifdef __NR_linkat
 # ifndef __ASSUME_ATFCTS
   if (__have_atfcts >= 0)
@@ -60,6 +53,13 @@ linkat (fromfd, from, tofd, to, flags)
 #endif
 
 #ifndef __ASSUME_ATFCTS
+  /* Without kernel support we cannot handle AT_SYMLINK_FOLLOW.  */
+  if (flags != 0)
+    {
+      __set_errno (EINVAL);
+      return -1;
+    }
+
   static const char procfd[] = "/proc/self/fd/%d/%s";
   char *buffrom = NULL;