Ticket #629 (closed bug: fixed)
IO library locking doesn't count readers
| Reported by: | simonmar | Owned by: | simonmar |
|---|---|---|---|
| Priority: | lowest | Milestone: | 6.8.3 |
| Component: | Compiler | Version: | 6.4.1 |
| Keywords: | Cc: | ||
| Operating System: | Unknown/Multiple | Architecture: | Unknown/Multiple |
| Type of failure: | Difficulty: | Unknown | |
| Test Case: | countReaders001 | Blocked By: | |
| Blocking: | Related Tickets: |
Description
We aren't keeping track of the number of readers of a file, so that the first one to close a Handle removes the lock.
> main = do > fc <- openFile "z" ReadMode -- sacrificial handle > fr <- openFile "z" ReadMode > hClose fc > fa <- openFile "z" AppendMode > hPutStr fa "append this line\n" > hGetLine fr >>= print
this should fail.
Change History
Note: See
TracTickets for help on using
tickets.
