Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix leaking with undefined key to release

  • Loading branch information...
commit 95527c11019b770bf9f806eb821087b0ddae011d 1 parent ded57a8
Michael Snoyman authored
2  resourcet/Control/Monad/Trans/Resource.hs
View
@@ -242,7 +242,7 @@ instance Exception InvalidAccess
release' :: I.IORef ReleaseMap
-> ReleaseKey
-> IO ()
-release' istate (ReleaseKey key) = E.mask $ \restore -> do
+release' istate (ReleaseKey key) = E.mask $ \restore -> key `seq` do
maction <- I.atomicModifyIORef istate lookupAction
maybe (return ()) restore maction
where
2  resourcet/resourcet.cabal
View
@@ -1,5 +1,5 @@
Name: resourcet
-Version: 0.3.2.1
+Version: 0.3.2.2
Synopsis: Deterministic allocation and freeing of scarce resources.
Description:
This package was originally included with the conduit package, and has since been split off. For more information, please see <http://www.yesodweb.com/book/conduits>.
Please sign in to comment.
Something went wrong with that request. Please try again.