diff --git a/System/Certificate/X509/MacOS.hs b/System/Certificate/X509/MacOS.hs
--- a/System/Certificate/X509/MacOS.hs
+++ b/System/Certificate/X509/MacOS.hs
@@ -18,6 +18,7 @@
 findCertificate f = do
   (_, Just hout, _, ph) <- createProcess (proc "security" ["find-certificate", "-pa", keyChain]) { std_out = CreatePipe }
   pems <- either error id . pemParseLBS <$> LBS.hGetContents hout
-  _ <- waitForProcess ph
   let targets = rights $ map (decodeCertificate . LBS.fromChunks .  pure . pemContent) $ filter ((=="CERTIFICATE") . pemName) pems
-  return $ listToMaybe $ filter f targets
+  let cert = listToMaybe $ filter f targets
+  _ <- cert `seq` waitForProcess ph
+  return cert
diff --git a/certificate.cabal b/certificate.cabal
--- a/certificate.cabal
+++ b/certificate.cabal
@@ -1,5 +1,5 @@
 Name:                certificate
-Version:             1.2.1
+Version:             1.2.2
 Description:
     Certificates and Key reader/writer
     .
