Merge with vlock-2
[vlock.git] / src / console_switch.h
blobe16f987eb2236ec797a4515f4691c5a7fffe7e2b
1 /* console_switch.c -- header file for the console grabbing
2 * routines for vlock, the VT locking program
3 * for linux
5 * This program is copyright (C) 2007 Frank Benkstein, and is free
6 * software which is freely distributable under the terms of the
7 * GNU General Public License version 2, included as the file COPYING in this
8 * distribution. It is NOT public domain software, and any
9 * redistribution not permitted by the GNU General Public License is
10 * expressly forbidden without prior written permission from
11 * the author.
15 #include <stdbool.h>
17 /* Is console switching currently disabled? */
18 extern bool console_switch_locked;
20 /* Disable virtual console switching in the kernel. On failure false
21 * is returned and errno is set. */
22 bool lock_console_switch(void);
23 /* Reenable console switching if it was previously disabled. On failure false
24 * is returned and errno is set. */
25 bool unlock_console_switch(void);