diff options
author | Joe Crayne <joe@jerkface.net> | 2020-05-10 12:36:22 -0400 |
---|---|---|
committer | Joe Crayne <joe@jerkface.net> | 2020-05-19 11:58:22 -0400 |
commit | de7e70d424da07993fbf3efcccbdb8b1d8bff82d (patch) | |
tree | 1a6182312fde8a0239f46a5ca68b6062fe5c877e /Data/OpenPGP/Util/Base.hs | |
parent | a0994da3aa361e1fff4d5e523e3b33341b0d245f (diff) |
Added HasCallStack to keyParam error call.
Diffstat (limited to 'Data/OpenPGP/Util/Base.hs')
-rw-r--r-- | Data/OpenPGP/Util/Base.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Data/OpenPGP/Util/Base.hs b/Data/OpenPGP/Util/Base.hs index 0c888ca..b43427c 100644 --- a/Data/OpenPGP/Util/Base.hs +++ b/Data/OpenPGP/Util/Base.hs | |||
@@ -30,6 +30,7 @@ import qualified Crypto.Types.PubKey.ECDSA as Vincent.ECDSA | |||
30 | #endif | 30 | #endif |
31 | import qualified Crypto.PubKey.RSA as Vincent.RSA | 31 | import qualified Crypto.PubKey.RSA as Vincent.RSA |
32 | import qualified Crypto.Random as Vincent | 32 | import qualified Crypto.Random as Vincent |
33 | import GHC.Stack | ||
33 | 34 | ||
34 | import Data.OpenPGP.Util.Fingerprint (fingerprint) | 35 | import Data.OpenPGP.Util.Fingerprint (fingerprint) |
35 | 36 | ||
@@ -85,7 +86,7 @@ find_key :: OpenPGP.Message -> String -> Maybe OpenPGP.Packet | |||
85 | find_key = OpenPGP.find_key (show . fingerprint) | 86 | find_key = OpenPGP.find_key (show . fingerprint) |
86 | 87 | ||
87 | 88 | ||
88 | keyParam :: Char -> OpenPGP.Packet -> Integer | 89 | keyParam :: HasCallStack => Char -> OpenPGP.Packet -> Integer |
89 | keyParam c k = fromJustMPI $ lookup c (OpenPGP.key k) | 90 | keyParam c k = fromJustMPI $ lookup c (OpenPGP.key k) |
90 | where | 91 | where |
91 | fromJustMPI :: Maybe OpenPGP.MPI -> Integer | 92 | fromJustMPI :: Maybe OpenPGP.MPI -> Integer |