summaryrefslogtreecommitdiffstats
path: root/openpgp/src/parse
diff options
context:
space:
mode:
authorJustus Winter <justus@sequoia-pgp.org>2020-11-17 16:54:32 +0100
committerJustus Winter <justus@sequoia-pgp.org>2020-12-07 16:37:57 +0100
commitd05f6cecbaeda0be9eae6a80517c1839d581545e (patch)
tree6af2ad42f85b623022056c36d5ffa5ec5e2283e5 /openpgp/src/parse
parent3b88cd1725bdded57c2ff845db5d471d2da63e6a (diff)
openpgp: Drop hash::Context in favor of a pub trait hash::Digest.
Diffstat (limited to 'openpgp/src/parse')
-rw-r--r--openpgp/src/parse/hashed_reader.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/openpgp/src/parse/hashed_reader.rs b/openpgp/src/parse/hashed_reader.rs
index a6aff9e7..bdaefe18 100644
--- a/openpgp/src/parse/hashed_reader.rs
+++ b/openpgp/src/parse/hashed_reader.rs
@@ -57,7 +57,7 @@ impl<R: BufferedReader<Cookie>> HashedReader<R> {
/// Updates the given hash context normalizing line endings to "\r\n"
/// on the fly.
-pub(crate) fn hash_update_text(h: &mut crate::crypto::hash::Context,
+pub(crate) fn hash_update_text(h: &mut dyn crate::crypto::hash::Digest,
text: &[u8]) {
let mut line = text;
while ! line.is_empty() {
@@ -271,7 +271,7 @@ impl<R: BufferedReader<Cookie>>
/// [`DetachedVerifier`]: ../parse/stream/struct.DetachedVerifier.html
pub(crate) fn hash_buffered_reader<R>(reader: R,
algos: &[HashingMode<HashAlgorithm>])
- -> Result<Vec<HashingMode<crate::crypto::hash::Context>>>
+ -> Result<Vec<HashingMode<Box<dyn crate::crypto::hash::Digest>>>>
where R: BufferedReader<crate::parse::Cookie>,
{
let mut reader