summaryrefslogtreecommitdiffstats
path: root/openpgp/src/parse/parse.rs
diff options
context:
space:
mode:
Diffstat (limited to 'openpgp/src/parse/parse.rs')
-rw-r--r--openpgp/src/parse/parse.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/openpgp/src/parse/parse.rs b/openpgp/src/parse/parse.rs
index a7b45ce2..25ca01f8 100644
--- a/openpgp/src/parse/parse.rs
+++ b/openpgp/src/parse/parse.rs
@@ -3700,13 +3700,13 @@ impl <'a> PacketParser<'a> {
let unread_content = if self.state.settings.buffer_unread_content {
t!("({:?} at depth {}): buffering {} bytes of unread content",
self.packet.tag(), recursion_depth,
- self.data_eof().unwrap().len());
+ self.data_eof().unwrap_or(&[]).len());
self.buffer_unread_content()?.len() > 0
} else {
t!("({:?} at depth {}): dropping {} bytes of unread content",
self.packet.tag(), recursion_depth,
- self.data_eof().unwrap().len());
+ self.data_eof().unwrap_or(&[]).len());
self.drop_eof()?
};