summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeal H. Walfield <neal@gnu.org>2017-11-16 20:44:23 +0100
committerNeal H. Walfield <neal@gnu.org>2017-11-16 20:44:23 +0100
commit1cf7a1052b124ed6ab9c5c2eac03a4e579900e29 (patch)
tree2cc59e5ce67ec655f57109914f3cd3d10d44d25e /src
parent8860798bef113e13da57c97ee925825409a349b7 (diff)
Make literal_body generic.
Diffstat (limited to 'src')
-rw-r--r--src/openpgp/parse/parse.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/openpgp/parse/parse.rs b/src/openpgp/parse/parse.rs
index 99ce5468..b41cb028 100644
--- a/src/openpgp/parse/parse.rs
+++ b/src/openpgp/parse/parse.rs
@@ -244,8 +244,8 @@ pub fn userid_body<T: BufferedReader>(bio: &mut T) -> Result<UserID, std::io::Er
}
/// Parse the body of a literal packet.
-pub fn literal_body(bio: &mut BufferedReader)
- -> Result<Literal, std::io::Error> {
+pub fn literal_body<R: BufferedReader>(mut bio: &mut R)
+ -> Result<Literal, std::io::Error> {
// When using bio, we have to do some acrobatics, because
// calling bio.data() creates a mutable borrow on bio. Since
// there can only be one such borrow at a time, we have to put it