1
0
mirror of https://github.com/openbsd/src.git synced 2025-01-10 06:47:55 -08:00

reduce pledge(2) to "stdio tty" after ncurses initialization.

OK tb@
This commit is contained in:
mestre 2018-08-23 06:25:01 +00:00
parent d967289559
commit c5ef424a48

View File

@ -1,4 +1,4 @@
/* $OpenBSD: grdc.c,v 1.28 2017/12/11 23:33:44 tb Exp $ */
/* $OpenBSD: grdc.c,v 1.29 2018/08/23 06:25:01 mestre Exp $ */
/*
*
* Copyright 2002 Amos Shapir. Public domain.
@ -97,6 +97,9 @@ main(int argc, char *argv[])
initscr();
if (pledge("stdio tty", NULL) == -1)
err(1, "pledge");
signal(SIGINT,sighndl);
signal(SIGTERM,sighndl);
signal(SIGHUP,sighndl);