summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2016-04-27 23:53:12 -0400
committerjoe <joe@jerkface.net>2016-04-27 23:53:12 -0400
commit368ae2d134ceb7ffbc3a5b1696574e7eb4d3e3d8 (patch)
treefaffb269ae644d1809f977546503552a07591519
parent94763e1e7928377ddc935bed497575c5df4941fb (diff)
fixed Prelude.!! crash.
-rw-r--r--cokiki.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/cokiki.hs b/cokiki.hs
index daebf0f..f8eed0a 100644
--- a/cokiki.hs
+++ b/cokiki.hs
@@ -176,7 +176,7 @@ configureTor uid root cmn = whenRoot uid root cmn $ do
176 $ (==p) . word 1 . concat . take 1 176 $ (==p) . word 1 . concat . take 1
177 177
178 word :: Int -> [L.ByteString] -> L.ByteString 178 word :: Int -> [L.ByteString] -> L.ByteString
179 word n toks = words !! n 179 word n toks = L.concat $ take 1 $ drop n words
180 where 180 where
181 words = filter (not . L8.any isSpace . L8.take 1) 181 words = filter (not . L8.any isSpace . L8.take 1)
182 toks 182 toks