Hi,

First, I am unsure about FIFO preprocessor variable use.

But it seems to me that just returning EOPNOTSUPP isn't good here: the
error code path at this point is to set `error' variable, and let code
after calling VOP_ABORTOP() and vrele()/vput().

Before, there is a namei(&nd) call with:
        NDINITAT(&nd, CREATE, LOCKPARENT, UIO_USERSPACE, fd, path, p);

Does it makes sens ?
-- 
Sebastien Marie


Index: kern/vfs_syscalls.c
===================================================================
RCS file: /cvs/src/sys/kern/vfs_syscalls.c,v
retrieving revision 1.256
diff -u -p -r1.256 vfs_syscalls.c
--- kern/vfs_syscalls.c 1 Jun 2016 22:54:45 -0000       1.256
+++ kern/vfs_syscalls.c 25 Jun 2016 07:21:45 -0000
@@ -1254,7 +1258,8 @@ domknodat(struct proc *p, int fd, const 
                        break;
                case S_IFIFO:
 #ifndef FIFO
-                       return (EOPNOTSUPP);
+                       error = EOPNOTSUPP;
+                       break;
 #else
                        if (dev == 0) {
                                vattr.va_type = VFIFO;

Reply via email to