svn commit: r259815 - stable/9/sys/fs/fifofs

Konstantin Belousov kib at FreeBSD.org
Tue Dec 24 07:26:44 UTC 2013


Author: kib
Date: Tue Dec 24 07:26:43 2013
New Revision: 259815
URL: http://svnweb.freebsd.org/changeset/base/259815

Log:
  MFC r259521:
  Do not allow O_EXEC opens for fifo, return EINVAL.

Modified:
  stable/9/sys/fs/fifofs/fifo_vnops.c
Directory Properties:
  stable/9/sys/   (props changed)
  stable/9/sys/fs/   (props changed)

Modified: stable/9/sys/fs/fifofs/fifo_vnops.c
==============================================================================
--- stable/9/sys/fs/fifofs/fifo_vnops.c	Tue Dec 24 07:25:49 2013	(r259814)
+++ stable/9/sys/fs/fifofs/fifo_vnops.c	Tue Dec 24 07:26:43 2013	(r259815)
@@ -194,7 +194,7 @@ fifo_open(ap)
 	int error;
 
 	ASSERT_VOP_ELOCKED(vp, "fifo_open");
-	if (fp == NULL)
+	if (fp == NULL || (ap->a_mode & FEXEC) != 0)
 		return (EINVAL);
 	if ((fip = vp->v_fifoinfo) == NULL) {
 		fip = malloc(sizeof(*fip), M_VNODE, M_WAITOK);


More information about the svn-src-stable-9 mailing list