diff --git a/hslogger.cabal b/hslogger.cabal
--- a/hslogger.cabal
+++ b/hslogger.cabal
@@ -1,10 +1,10 @@
 Name: hslogger
-Version: 1.2.10
+Version: 1.2.12
 License: BSD3
 Maintainer: John Goerzen <jgoerzen@complete.org>
 Author: John Goerzen
 Stability: Stable
-Copyright: Copyright (c) 2004-2012 John Goerzen
+Copyright: Copyright (c) 2004-2018 John Goerzen
 license-file: LICENSE
 build-type: Simple
 Homepage: http://software.complete.org/hslogger
diff --git a/src/System/Log/Handler/Simple.hs b/src/System/Log/Handler/Simple.hs
--- a/src/System/Log/Handler/Simple.hs
+++ b/src/System/Log/Handler/Simple.hs
@@ -3,7 +3,7 @@
    Copyright  : Copyright (C) 2004-2011 John Goerzen
    License    : BSD3
 
-   Maintainer : John Goerzen <jgoerzen@complete.org> 
+   Maintainer : John Goerzen <jgoerzen@complete.org>
    Stability  : provisional
    Portability: portable
 
@@ -17,16 +17,14 @@
                                       verboseStreamHandler)
     where
 
-#if !MIN_VERSION_base(4,6,0)
-import Prelude hiding (catch)
-#endif
-import Control.Exception (SomeException, catch)
+import Control.Exception (SomeException, tryJust)
 import Data.Char (ord)
 
 import System.Log
 import System.Log.Handler
 import System.Log.Formatter
 import System.IO
+import System.IO.Error
 import Control.Concurrent.MVar
 
 {- | A helper data type. -}
@@ -64,9 +62,12 @@
                                writeFunc = mywritefunc,
                                closeFunc = \x -> return ()})
     where
-      writeToHandle hdl msg =
-          hPutStrLn hdl msg `catch` (handleWriteException hdl msg)
-      handleWriteException :: Handle -> String -> SomeException -> IO ()
+      writeToHandle hdl msg = do
+          rv <- tryJust myException (hPutStrLn hdl msg)
+          either (handleWriteException hdl msg) return rv
+      myException e
+          | isDoesNotExistError e = Just e
+          | otherwise = Nothing
       handleWriteException hdl msg e =
           let msg' = "Error writing log message: " ++ show e ++
                      " (original message: " ++ msg ++ ")"
diff --git a/src/System/Log/Logger.hs b/src/System/Log/Logger.hs
--- a/src/System/Log/Logger.hs
+++ b/src/System/Log/Logger.hs
@@ -472,11 +472,11 @@
     do l <- getLogger ln
        saveGlobalLogger (func l)
 
--- | Allow gracefull shutdown. Release all opened files/handlers/etc.
+-- | Allow graceful shutdown. Release all opened files/handlers/etc.
 removeAllHandlers :: IO ()
 removeAllHandlers =
     modifyMVar_ logTree $ \lt -> do
-        let allHandlers = Map.fold (\l r -> concat [r, handlers l]) [] lt
+        let allHandlers = Map.foldr (\l r -> concat [r, handlers l]) [] lt
         mapM_ (\(HandlerT h) -> close h) allHandlers
         return $ Map.map (\l -> l {handlers = []}) lt
 
