on master help sign in
Fix the hGetContents crash test

--HG-- extra : convert_revision : 766ae2caf59ba5481cf4cecc4fe07a47edabfca4

commitc051a63187d830dbe232219b6fde659df8004dbc authorBryan O'Sullivan <bos@serpentine.com> dateThu 26 Aug 2010, 02:12 (16 years ago) parent741d65d
1 file changed+1−1
Data/Text/IO.hs+1−1
Data/Text/IO.hs+1−1
@@ -102,9 +102,9 @@ hGetContents h = do
102102 (hh',ts) <- readChunks
103103 return (hh', t:ts)
104104 readChunks `catch` \e -> do
105− (hh', _) <- hClose_help hh
106105 if isEOFError e
107106 then do
107+ (hh', _) <- hClose_help hh
108108 buf <- readIORef haCharBuffer
109109 return $ if isEmptyBuffer buf
110110 then (hh', [])