summaryrefslogtreecommitdiff
path: root/packages/xorg-xserver/xserver-kdrive-1.4/keyboard-resume-workaround.patch
blob: ced19049165e5667d47cbcbbfb5e58acc0d6ba2e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Index: xorg-server-1.4/hw/kdrive/linux/keyboard.c
===================================================================
--- xorg-server-1.4.orig/hw/kdrive/linux/keyboard.c	2007-09-29 18:31:15.000000000 +0200
+++ xorg-server-1.4/hw/kdrive/linux/keyboard.c	2007-09-29 18:33:02.000000000 +0200
@@ -743,11 +743,8 @@
     cfsetispeed(&nTty, 9600);
     cfsetospeed(&nTty, 9600);
     tcsetattr(fd, TCSANOW, &nTty);
-    /*
-     * Flush any pending keystrokes
-     */
-    while ((n = read (fd, buf, sizeof (buf))) > 0)
-	;
+    n = fcntl(fd, F_GETFL);
+    fprintf(stderr, "LinuxConsoleFd status flags: %x (O_NONBLOCK = %x)\n", n, O_NONBLOCK);
     KdRegisterFd (fd, LinuxKeyboardRead, ki);
     return Success;
 }