From 6f6f85f11980e782917cb84c7a66c24f41f19ac3 Mon Sep 17 00:00:00 2001 From: joe Date: Sun, 16 Mar 2014 18:42:38 -0400 Subject: Fixed pty device names --- Presence/ConsoleWriter.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Presence/ConsoleWriter.hs') diff --git a/Presence/ConsoleWriter.hs b/Presence/ConsoleWriter.hs index aca4bf98..9fce6701 100644 --- a/Presence/ConsoleWriter.hs +++ b/Presence/ConsoleWriter.hs @@ -254,8 +254,9 @@ writeAllPty cw msg = do us <- atomically $ readTVar (csUtmp cw) let ptys = Map.filterWithKey ispty us ispty k _ = "pts/" `Text.isPrefixOf` k + && Text.all isDigit (Text.drop 4 k) bs <- forM (Map.toList ptys) $ \(tty,utmp) -> do - deliverTerminalMessage cw tty utmp msg + deliverTerminalMessage cw ("/dev/" <> tty) utmp msg return $ or bs resource :: UtmpRecord -> Text -- cgit v1.2.3