summaryrefslogtreecommitdiffstats
path: root/tdm/backend/ctrl.c
diff options
context:
space:
mode:
Diffstat (limited to 'tdm/backend/ctrl.c')
-rw-r--r--tdm/backend/ctrl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tdm/backend/ctrl.c b/tdm/backend/ctrl.c
index 1e7cfd07a..200b7056b 100644
--- a/tdm/backend/ctrl.c
+++ b/tdm/backend/ctrl.c
@@ -41,6 +41,7 @@ from the copyright holder.
#include <string.h>
#include <signal.h>
#include <pwd.h>
+#include <sys/ioctl.h>
#include <sys/stat.h>
#ifdef __linux__
@@ -591,7 +592,7 @@ processCtrl( const char *string, int len, int fd, struct display *d )
} else if (fd >= 0 && !strcmp( ar[0], "activevt" )) {
#ifdef HAVE_VTS
Reply( "ok" );
- int vt_fd = getfd(NULL);
+ int vt_fd = getfd();
if (vt_fd > 0) {
struct vt_stat vtstat;
if (!ioctl(vt_fd, VT_GETSTATE, &vtstat)) {