Revision d5072e4c htools/hscan.hs

b/htools/hscan.hs
153 153
         let name = local
154 154
         input_data <- Luxi.loadData lsock
155 155
         result <- writeData nlen name opts input_data
156
         when (not result) $ exitWith $ ExitFailure 2
156
         unless result $ exitWith $ ExitFailure 2
157 157

  
158 158
#ifndef NO_CURL
159
  results <- mapM (\ name ->
160
                    do
161
                      input_data <- Rapi.loadData name
162
                      writeData nlen name opts input_data
163
                  ) clusters
164
  when (not $ all id results) $ exitWith (ExitFailure 2)
159
  results <- mapM (\name -> Rapi.loadData name >>= writeData nlen name opts)
160
             clusters
161
  unless (all id results) $ exitWith (ExitFailure 2)
165 162
#else
166 163
  when (not $ null clusters) $ do
167 164
    putStrLn "RAPI/curl backend disabled at compile time, cannot scan clusters"

Also available in: Unified diff