posix-pty 0.2.0.1 → 0.2.1
raw patch · 2 files changed
+7/−2 lines, 2 files
Files
- System/Posix/Pty.hs +6/−1
- posix-pty.cabal +1/−1
System/Posix/Pty.hs view
@@ -25,6 +25,7 @@ , PtyControlCode (..) -- * Pty Interaction Functions , createPty+ , closePty , tryReadPty , readPty , writePty@@ -71,7 +72,7 @@ import Foreign.C.Types import System.IO.Error (mkIOError, eofErrorType)-import System.Posix.IO (fdReadBuf, fdWriteBuf)+import System.Posix.IO (fdReadBuf, fdWriteBuf,closeFd) import System.Posix.Types import System.Process.Internals (mkProcessHandle, ProcessHandle) @@ -119,6 +120,10 @@ let result | isTerminal = Just (Pty fd) | otherwise = Nothing return result++-- | Close this pseudo terminal.+closePty :: Pty -> IO ()+closePty (Pty fd) = closeFd fd -- | Attempt to read data from a pseudo terminal. Produces either the data read -- or a list of 'PtyControlCode'@s@ indicating which control status events that
posix-pty.cabal view
@@ -1,5 +1,5 @@ Name: posix-pty-Version: 0.2.0.1+Version: 0.2.1 Homepage: https://bitbucket.org/merijnv/posix-pty Bug-Reports: https://github.com/merijn/posix-pty/issues