summaryrefslogtreecommitdiff
path: root/KeyRing.hs
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2014-04-30 21:03:38 -0400
committerjoe <joe@jerkface.net>2014-04-30 21:03:38 -0400
commitc218706406bd627758db320d8609c56e9b7bbbab (patch)
treebff17c1d3a942a99530d1d6ad22fe7c2e026071b /KeyRing.hs
parent3c31d32a259dcb81741c2bdd5f2ba46ab26fe08a (diff)
Oops. Now its consistent.
Diffstat (limited to 'KeyRing.hs')
-rw-r--r--KeyRing.hs7
1 files changed, 6 insertions, 1 deletions
diff --git a/KeyRing.hs b/KeyRing.hs
index bcd8ac8..53e7438 100644
--- a/KeyRing.hs
+++ b/KeyRing.hs
@@ -1608,9 +1608,14 @@ writePEMKeys doDecrypt db exports = do
1608makeMemoizingDecrypter :: KeyRingOperation -> InputFileContext 1608makeMemoizingDecrypter :: KeyRingOperation -> InputFileContext
1609 -> IO (MappedPacket -> IO (KikiCondition Packet)) 1609 -> IO (MappedPacket -> IO (KikiCondition Packet))
1610makeMemoizingDecrypter operation ctx = do 1610makeMemoizingDecrypter operation ctx = do
1611 -- (*) Notice we do not pass ctx to resolveForReport.
1612 -- This is because the merge function does not currently use a context
1613 -- and the pws map keys must match the MappedPacket locations.
1614 -- TODO: Perhaps these should both be of type InputFile rather than
1615 -- FilePath?
1611 pws <- 1616 pws <-
1612 Traversable.mapM (cachedContents ctx . fromJust . pwfile . typ) 1617 Traversable.mapM (cachedContents ctx . fromJust . pwfile . typ)
1613 (Map.mapKeys (resolveForReport $ Just ctx) 1618 (Map.mapKeys (resolveForReport Nothing) -- see note (*) note above
1614 $ Map.filter (isJust . pwfile . typ) $ kFiles operation) 1619 $ Map.filter (isJust . pwfile . typ) $ kFiles operation)
1615 unkeysRef <- newIORef Map.empty 1620 unkeysRef <- newIORef Map.empty
1616 return $ doDecrypt unkeysRef pws 1621 return $ doDecrypt unkeysRef pws