From bdd4468047bac66dbca45b7a75475845b3cbd0b3 Mon Sep 17 00:00:00 2001 From: deraadt Date: Thu, 15 Oct 2015 17:55:41 +0000 Subject: [PATCH] Add TIOCFLUSH to "tty" in support of tcflush() --- sys/kern/kern_pledge.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/kern/kern_pledge.c b/sys/kern/kern_pledge.c index d9fcdd27724..ac077df2697 100644 --- a/sys/kern/kern_pledge.c +++ b/sys/kern/kern_pledge.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_pledge.c,v 1.29 2015/10/15 17:50:05 deraadt Exp $ */ +/* $OpenBSD: kern_pledge.c,v 1.30 2015/10/15 17:55:41 deraadt Exp $ */ /* * Copyright (c) 2015 Nicholas Marriott @@ -1101,6 +1101,7 @@ pledge_ioctl_check(struct proc *p, long com, void *v) case TIOCSETA: /* cu, ... */ case TIOCSETAW: /* cu, ... */ case TIOCSETAF: /* tcsetattr TCSAFLUSH, script */ + case TIOCFLUSH: /* getty */ if (fp->f_type == DTYPE_VNODE && (vp->v_flag & VISTTY)) return (0); break; -- 2.20.1