summaryrefslogtreecommitdiffstats
path: root/openpgp/src/serialize/stream.rs
diff options
context:
space:
mode:
authorJustus Winter <justus@sequoia-pgp.org>2019-12-03 13:31:25 +0100
committerJustus Winter <justus@sequoia-pgp.org>2019-12-03 13:31:25 +0100
commit88442e46a8f5639c4493713baeb5b90f7cf6a84b (patch)
tree6ef574940c13e9d7245c64d2dfea1ede2d91770e /openpgp/src/serialize/stream.rs
parent3731a890de264f1f7def2af50b4e6abde536fb76 (diff)
openpgp: Make Literal::set_filename polymorphic over AsRef<[u8]>.
- And drop Literal::set_filename_from_bytes.
Diffstat (limited to 'openpgp/src/serialize/stream.rs')
-rw-r--r--openpgp/src/serialize/stream.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/openpgp/src/serialize/stream.rs b/openpgp/src/serialize/stream.rs
index 2b53cb7a..40b18984 100644
--- a/openpgp/src/serialize/stream.rs
+++ b/openpgp/src/serialize/stream.rs
@@ -578,7 +578,7 @@ impl<'a> LiteralWriter<'a> {
/// The standard does not specify the encoding. Filenames must
/// not be longer than 255 bytes.
pub fn filename<B: AsRef<[u8]>>(mut self, filename: B) -> Result<Self> {
- self.template.set_filename_from_bytes(filename.as_ref())?;
+ self.template.set_filename(filename.as_ref())?;
Ok(self)
}