Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions AppleScript.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,9 @@ if os(darwin) {
network < 2.4,
conduit < 0.3,
directory < 1.2,
template-haskell == 2.7.*,
mtl == 2.0.*
template-haskell >= 2.7,
mtl >= 2.0,
resourcet == 1.1.3
Exposed-modules:
Foreign.AppleScript
Foreign.AppleScript.Error
Expand Down
8 changes: 4 additions & 4 deletions Foreign/AppleScript/Rich.hs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
TypeSynonymInstances,
FlexibleInstances
#-}
{-# OPTIONS_GHC -funbox-strict-fields -Wall -Werror #-}
{-# OPTIONS_GHC -funbox-strict-fields -Wall #-}

-- |
-- This module supports a \"rich\" communication with AppleScript. Specifically, this
Expand Down Expand Up @@ -72,7 +72,7 @@ import qualified Foreign.AppleScript.Plain as Plain
import Control.Applicative
import Control.Monad.State
import Control.Monad.Writer
import Control.Monad.Trans.Resource(ResourceT, runResourceT, withIO)
import Control.Monad.Trans.Resource(ResourceT, runResourceT, allocate)

import Control.Exception(tryJust, finally)
import Control.Concurrent(forkIO, killThread)
Expand Down Expand Up @@ -276,11 +276,11 @@ runScriptFull conf script = runResourceT $ do

-- start the callback server
(_, sock) <- lift $
withIO
allocate
(listenOn (PortNumber port))
sClose
-- (const $ return ())
void $ lift $ withIO
void $ lift $ allocate
(forkIO $ serverLoop handler sock)
killThread

Expand Down