On Tue, Jul 12, 2011, Christian Weisgerber wrote:
> Matthew Dempsky <[email protected]> wrote:
>
>> Now that all of the new AT_* flags are supported, it's okay to expose
>> openat(2), etc. in libc.
>
> ... revealing that the gnulib configure tests think that our
> fchownat() is broken.
fix:
Index: vfs_syscalls.c
===================================================================
RCS file: /home/tedu/cvs/src/sys/kern/vfs_syscalls.c,v
retrieving revision 1.174
diff -u -p -r1.174 vfs_syscalls.c
--- vfs_syscalls.c 9 Jul 2011 05:46:26 -0000 1.174
+++ vfs_syscalls.c 12 Jul 2011 23:12:02 -0000
@@ -2054,7 +2054,7 @@ dofchownat(struct proc *p, int fd, const
return (EINVAL);
follow = (flag & AT_SYMLINK_NOFOLLOW) ? NOFOLLOW : FOLLOW;
- NDINITAT(&nd, LOOKUP, FOLLOW, UIO_USERSPACE, fd, path, p);
+ NDINITAT(&nd, LOOKUP, follow, UIO_USERSPACE, fd, path, p);
if ((error = namei(&nd)) != 0)
return (error);
vp = nd.ni_vp;