From ead73f75ff035d474433ecd9bd0e196c4aca155b Mon Sep 17 00:00:00 2001 From: semarie Date: Sun, 26 Jun 2016 14:27:14 +0000 Subject: [PATCH] use error code path instead of return early without calling VOP_ABORTOP() and vrele()/vput(). ok deraadt@ --- sys/kern/vfs_syscalls.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 8cf313f81ca..ffaaefa6380 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vfs_syscalls.c,v 1.256 2016/06/01 22:54:45 millert Exp $ */ +/* $OpenBSD: vfs_syscalls.c,v 1.257 2016/06/26 14:27:14 semarie Exp $ */ /* $NetBSD: vfs_syscalls.c,v 1.71 1996/04/23 10:29:02 mycroft Exp $ */ /* @@ -1254,7 +1254,8 @@ domknodat(struct proc *p, int fd, const char *path, mode_t mode, dev_t dev) break; case S_IFIFO: #ifndef FIFO - return (EOPNOTSUPP); + error = EOPNOTSUPP; + break; #else if (dev == 0) { vattr.va_type = VFIFO; -- 2.20.1