diff --git a/sys/src/cmd/aux/kbdfs/kbdfs.c b/sys/src/cmd/aux/kbdfs/kbdfs.c index 9932f8dae..004e99e76 100644 --- a/sys/src/cmd/aux/kbdfs/kbdfs.c +++ b/sys/src/cmd/aux/kbdfs/kbdfs.c @@ -1156,7 +1156,8 @@ fsdestroyfid(Fid *f) } break; case Qkbd: - kbdopen--; + if(--kbdopen == 0) + sendul(ctlchan, Kbdflush); break; case Qcons: consopen--;