summaryrefslogtreecommitdiff
path: root/sys/src/cmd/rio/rio.c
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2014-10-25 02:05:44 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2014-10-25 02:05:44 +0200
commitc38cd508057ab0abda846ed13786d56d627db7e2 (patch)
tree11a540f2c176dcb08b9e28bef65a13176c494628 /sys/src/cmd/rio/rio.c
parent88486c75292e2138ebe861ca0130503c21d2f110 (diff)
rio: dont serve a kbd file per window when we didnt got one from the environment
9vx doesnt provide a /dev/kbd file and rio faking one up causes problems with vncv. (issue #223)
Diffstat (limited to 'sys/src/cmd/rio/rio.c')
-rw-r--r--sys/src/cmd/rio/rio.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/src/cmd/rio/rio.c b/sys/src/cmd/rio/rio.c
index 26b9b227d..5d7fe2e91 100644
--- a/sys/src/cmd/rio/rio.c
+++ b/sys/src/cmd/rio/rio.c
@@ -1340,6 +1340,9 @@ kbdproc(void *arg)
if((kfd = open("/dev/kbd", OREAD)) >= 0){
close(fd);
+ /* only serve a kbd file per window when we got one */
+ servekbd = 1;
+
/* read kbd state */
while((n = read(kfd, buf, sizeof(buf))) > 0)
chanprint(c, "%.*s", n, buf);