#4006: System.Process doesn't encode its arguments.
---------------------------------+------------------------------------------
Reporter: Khudyakov | Owner:
Type: bug | Status: new
Priority: normal | Component: libraries/process
Version: 6.12.1 | Keywords:
Os: Linux | Testcase:
Architecture: Unknown/Multiple | Failure: None/Unknown
Patch: 0 |
---------------------------------+------------------------------------------
System.Process doesn't encode strings while creating new processes. It
truncate them instead. Here is simple test case. testUnicode should always
return True but does so only for ASCII string.
{{{
testUnicode :: String -> IO Bool
testUnicode str = ((== str) . init) `fmap` (readProcess "echo" [str] "")
}}}
In GHCi I get following:
{{{
*Main> testUnicode "It works here"
True
*Main> testUnicode "А здесь сломалось"
False
}}}
I think this bug isn't controversial like #3307 and #3309 since there is
no possible information loss.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4006>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs