about summary refs log tree commit diff
path: root/tvix/store/src/nar
diff options
context:
space:
mode:
Diffstat (limited to 'tvix/store/src/nar')
-rw-r--r--tvix/store/src/nar/renderer.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/tvix/store/src/nar/renderer.rs b/tvix/store/src/nar/renderer.rs
index 80bf9bc6d816..97dfcfee6e32 100644
--- a/tvix/store/src/nar/renderer.rs
+++ b/tvix/store/src/nar/renderer.rs
@@ -13,10 +13,10 @@ use tracing::warn;
 
 /// Invoke [render_nar], and return the size and sha256 digest of the produced
 /// NAR output.
-pub fn calculate_size_and_sha256<DS: DirectoryService + Clone>(
+pub fn calculate_size_and_sha256(
     root_node: &proto::node::Node,
     blob_service: &Box<dyn BlobService>,
-    directory_service: DS,
+    directory_service: &Box<dyn DirectoryService>,
 ) -> Result<(u64, [u8; 32]), RenderError> {
     let h = Sha256::new();
     let mut cw = CountWrite::from(h);
@@ -30,11 +30,11 @@ pub fn calculate_size_and_sha256<DS: DirectoryService + Clone>(
 /// and uses the passed blob_service and directory_service to
 /// perform the necessary lookups as it traverses the structure.
 /// The contents in NAR serialization are writen to the passed [std::io::Write].
-pub fn write_nar<W: std::io::Write, DS: DirectoryService + Clone>(
+pub fn write_nar<W: std::io::Write>(
     w: &mut W,
     proto_root_node: &proto::node::Node,
     blob_service: &Box<dyn BlobService>,
-    directory_service: DS,
+    directory_service: &Box<dyn DirectoryService>,
 ) -> Result<(), RenderError> {
     // Initialize NAR writer
     let nar_root_node = nar::writer::open(w).map_err(RenderError::NARWriterError)?;
@@ -49,11 +49,11 @@ pub fn write_nar<W: std::io::Write, DS: DirectoryService + Clone>(
 
 /// Process an intermediate node in the structure.
 /// This consumes the node.
-fn walk_node<DS: DirectoryService + Clone>(
+fn walk_node(
     nar_node: nar::writer::Node,
     proto_node: &proto::node::Node,
     blob_service: &Box<dyn BlobService>,
-    directory_service: DS,
+    directory_service: &Box<dyn DirectoryService>,
 ) -> Result<(), RenderError> {
     match proto_node {
         proto::node::Node::Symlink(proto_symlink_node) => {