From 17c421984737ce09b168881d9a3d60c1ec1b1e8b Mon Sep 17 00:00:00 2001 From: semarie Date: Wed, 7 Oct 2015 17:27:35 +0000 Subject: [PATCH] from previous commit: "ioctl" is used for grab ttyname(0) with a function's name like that "tty" should be a better request (more strict) pointed by and ok deraadt@ --- usr.bin/who/who.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.bin/who/who.c b/usr.bin/who/who.c index 63dc95c83b4..0bf8b179669 100644 --- a/usr.bin/who/who.c +++ b/usr.bin/who/who.c @@ -1,4 +1,4 @@ -/* $OpenBSD: who.c,v 1.21 2015/10/07 16:11:40 semarie Exp $ */ +/* $OpenBSD: who.c,v 1.22 2015/10/07 17:27:35 semarie Exp $ */ /* $NetBSD: who.c,v 1.4 1994/12/07 04:28:49 jtc Exp $ */ /* @@ -74,7 +74,7 @@ main(int argc, char *argv[]) setlocale(LC_ALL, ""); - if (tame("stdio getpw rpath ioctl", NULL) == -1) + if (tame("stdio getpw rpath tty", NULL) == -1) err(1, "tame"); mytty = ttyname(0); -- 2.20.1