Module Name: src Committed By: riastradh Date: Thu Apr 9 05:03:58 UTC 2015
Modified Files: src/sys/kern: vfs_syscalls.c src/tests/fs/vfs: t_vnops.c Log Message: Tests claim rename(..., "x/.") yields EISDIR, so do that. Fixes zfs. To generate a diff of this commit: cvs rdiff -u -r1.493 -r1.494 src/sys/kern/vfs_syscalls.c cvs rdiff -u -r1.46 -r1.47 src/tests/fs/vfs/t_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/vfs_syscalls.c diff -u src/sys/kern/vfs_syscalls.c:1.493 src/sys/kern/vfs_syscalls.c:1.494 --- src/sys/kern/vfs_syscalls.c:1.493 Sun Feb 15 10:48:21 2015 +++ src/sys/kern/vfs_syscalls.c Thu Apr 9 05:03:58 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_syscalls.c,v 1.493 2015/02/15 10:48:21 martin Exp $ */ +/* $NetBSD: vfs_syscalls.c,v 1.494 2015/04/09 05:03:58 riastradh Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -70,7 +70,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls.c,v 1.493 2015/02/15 10:48:21 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_syscalls.c,v 1.494 2015/04/09 05:03:58 riastradh Exp $"); #ifdef _KERNEL_OPT #include "opt_fileassoc.h" @@ -4286,7 +4286,7 @@ do_sys_renameat(struct lwp *l, int fromf ((tnd.ni_cnd.cn_namelen == 2) && (tnd.ni_cnd.cn_nameptr[0] == '.') && (tnd.ni_cnd.cn_nameptr[1] == '.'))) { - error = EINVAL; /* XXX EISDIR? */ + error = EISDIR; goto abort1; } Index: src/tests/fs/vfs/t_vnops.c diff -u src/tests/fs/vfs/t_vnops.c:1.46 src/tests/fs/vfs/t_vnops.c:1.47 --- src/tests/fs/vfs/t_vnops.c:1.46 Thu Apr 9 05:02:28 2015 +++ src/tests/fs/vfs/t_vnops.c Thu Apr 9 05:03:58 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: t_vnops.c,v 1.46 2015/04/09 05:02:28 riastradh Exp $ */ +/* $NetBSD: t_vnops.c,v 1.47 2015/04/09 05:03:58 riastradh Exp $ */ /*- * Copyright (c) 2010 The NetBSD Foundation, Inc. @@ -274,8 +274,6 @@ rename_dir(const atf_tc_t *tc, const cha md(pb1, mp, "dir3/."); if (rump_sys_rename(pb1, pb3) != -1 || errno != EINVAL) atf_tc_fail_errno("rename 2"); - if (FSTYPE_ZFS(tc)) - atf_tc_expect_fail("PR kern/47656: Test known to be broken"); if (rump_sys_rename(pb3, pb1) != -1 || errno != EISDIR) atf_tc_fail_errno("rename 3");