lidm/include/chvt.h
javalsai dbbab78e23
format: let clang-format run ._.
(won't even talk about clang-tidy)
2024-09-05 20:26:58 +02:00

26 lines
491 B
C

#ifndef _CHVTH_
#define _CHVTH_
#include <fcntl.h>
#include <linux/kd.h>
#include <linux/vt.h>
#include <sys/ioctl.h>
#include <unistd.h>
/**
* @brief change foreground virtual terminal to `n`
*
* @param n virtual terminal number
* @return int non-negative value on success
*/
int chvt(int n);
/**
* @brief change foreground virtual terminal to `str`
*
* @param str virtual terminal number (string)
* @return int non-negative value on success
*/
int chvt_str(char *str);
#endif