From ce42d55fedf6e092dfaed5cb3c30f0f4fa04c10d Mon Sep 17 00:00:00 2001 From: helg Date: Mon, 27 Nov 2017 22:55:18 +0000 Subject: Change fusefs_link to return EPERM if the source file is a directory. Now aligns with link(2) man page and ffs regress tests. ok phessler@, jca@ --- sys/miscfs/fuse/fuse_vnops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys') diff --git a/sys/miscfs/fuse/fuse_vnops.c b/sys/miscfs/fuse/fuse_vnops.c index bf3f86ee184..80585d0e8d5 100644 --- a/sys/miscfs/fuse/fuse_vnops.c +++ b/sys/miscfs/fuse/fuse_vnops.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fuse_vnops.c,v 1.35 2017/11/27 12:54:13 helg Exp $ */ +/* $OpenBSD: fuse_vnops.c,v 1.36 2017/11/27 22:55:17 helg Exp $ */ /* * Copyright (c) 2012-2013 Sylvestre Gallon * @@ -565,7 +565,7 @@ fusefs_link(void *v) } if (vp->v_type == VDIR) { VOP_ABORTOP(dvp, cnp); - error = EISDIR; + error = EPERM; goto out2; } if (dvp->v_mount != vp->v_mount) { -- cgit v1.2.3