creatur 5.9.16 → 5.9.17
raw patch · 2 files changed
+12/−13 lines, 2 filesdep ~creaturdep ~hdaemonizedep ~hsyslog
Dependency ranges changed: creatur, hdaemonize, hsyslog, temporary, test-framework-quickcheck2
Files
- creatur.cabal +9/−9
- src/ALife/Creatur/Daemon.hs +3/−4
creatur.cabal view
@@ -1,5 +1,5 @@ name: creatur-version: 5.9.16+version: 5.9.17 cabal-version: >=1.8 build-type: Simple license: BSD3@@ -59,7 +59,7 @@ ALife.Creatur.Util build-depends: array >=0.5.1.1 && <0.6,- base >=4.9.1.0 && <4.10,+ base ==4.9.*, bytestring >=0.10.8.1 && <0.11, cond >=0.4.1.1 && <0.5, cereal >=0.5.4.0 && <0.6,@@ -67,8 +67,8 @@ exceptions >=0.8.3 && <0.9, filepath >=1.4.1.1 && <1.5, gray-extended >=1.5.2 && <1.6,- hdaemonize >=0.5.3 && <0.6,- hsyslog >=4 && <4.1,+ hdaemonize >=0.5.4 && <0.6,+ hsyslog >=5.0.1 && <5.1, MonadRandom >=0.5.1 && <0.6, mtl >=2.2.1 && <2.3, old-locale >=1.0.0.7 && <1.1,@@ -89,20 +89,20 @@ main-is: TestAll.hs build-depends: array >=0.5.1.1 && <0.6,- base >=4.9.1.0 && <4.10,+ base ==4.9.*, binary >=0.8.3.0 && <0.9, cereal >=0.5.4.0 && <0.6,- creatur >=5.9.16 && <5.10,+ creatur, directory >=1.3.0.0 && <1.4, filepath >=1.4.1.1 && <1.5,- hsyslog >=4 && <4.1,+ hsyslog >=5.0.1 && <5.1, HUnit >=1.5.0.0 && <1.6, MonadRandom >=0.5.1 && <0.6, mtl >=2.2.1 && <2.3,- temporary >=1.2.0.4 && <1.3,+ temporary >=1.2.1 && <1.3, test-framework >=0.8.1.1 && <0.9, test-framework-hunit >=0.3.0.2 && <0.4,- test-framework-quickcheck2 >=0.3.0.3 && <0.4,+ test-framework-quickcheck2 >=0.3.0.4 && <0.4, QuickCheck >=2.9.2 && <2.10 hs-source-dirs: test other-modules:
src/ALife/Creatur/Daemon.hs view
@@ -29,14 +29,13 @@ import Control.Exception (SomeException, handle, catch) import Control.Monad (when) import Control.Monad.State (StateT, execStateT)-import Data.ByteString.Char8 (pack)+import Foreign.C.String (withCStringLen) import System.IO (hPutStr, stderr) import System.IO.Unsafe (unsafePerformIO) import qualified System.Posix.Daemonize as D import System.Posix.Signals (Handler(Catch), fullSignalSet, installHandler, sigTERM)-import System.Posix.Syslog (Priority(Warning), Facility(DAEMON),- syslogUnsafe)+import System.Posix.Syslog (Priority(Warning), Facility(Daemon), syslog) import System.Posix.User (getLoginName, getRealUserID) termReceived :: MVar Bool@@ -114,7 +113,7 @@ wrap t = catch t (\e -> do let err = show (e :: SomeException)- syslogUnsafe DAEMON Warning $ pack ("Unhandled exception: " ++ err)+ withCStringLen ("Unhandled exception: " ++ err) $ syslog (Just Daemon) Warning hPutStr stderr ("Unhandled exception: " ++ err) return ())