[pbs-devel] [PATCH v4 pxar 02/58] decoder: add method to read payload references
Christian Ebner
c.ebner at proxmox.com
Mon Apr 29 14:10:06 CEST 2024
This is in preparation for reading payloads from a dedicated payload
input stream.
Signed-off-by: Christian Ebner <c.ebner at proxmox.com>
---
src/decoder/mod.rs | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/decoder/mod.rs b/src/decoder/mod.rs
index d1fb911..9dce7b2 100644
--- a/src/decoder/mod.rs
+++ b/src/decoder/mod.rs
@@ -661,6 +661,11 @@ impl<I: SeqRead> DecoderImpl<I> {
async fn read_quota_project_id(&mut self) -> io::Result<format::QuotaProjectId> {
self.read_simple_entry("quota project id").await
}
+
+ async fn read_payload_ref(&mut self) -> io::Result<format::PayloadRef> {
+ self.current_header.check_header_size()?;
+ seq_read_entry(&mut self.input).await
+ }
}
/// Reader for file contents inside a pxar archive.
--
2.39.2
More information about the pbs-devel
mailing list