[GHC] #11997: hSetFileSize zeroes file
GHC
ghc-devs at haskell.org
Fri Apr 29 23:05:10 UTC 2016
#11997: hSetFileSize zeroes file
-------------------------------------+-------------------------------------
Reporter: jacereda | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: | Version: 7.10.3
libraries/base |
Keywords: | Operating System: MacOS X
Architecture: x86_64 | Type of failure: Incorrect result
(amd64) | at runtime
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
The following sequence:
{{{
cp /bin/echo /tmp/echo && ghc -e 'import System.IO' -e 'withFile
"/tmp/echo" WriteMode (`hSetFileSize` 1000)'
}}}
results in /tmp/echo containing 1000 zeros. I would expect the truncated
content as if truncate() was called.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11997>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list