about summary refs log tree commit diff
path: root/tvix/glue/src/tvix_store_io.rs
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2024-06-25T18·48+0300
committerflokli <flokli@flokli.de>2024-06-26T04·51+0000
commit540e5669007a5f21b24bb8c63fd89756d0176866 (patch)
treeb77dea5cb4841448588cf20e058513d0eb1d9ac1 /tvix/glue/src/tvix_store_io.rs
parent78eb22c54d304715f527fa0e350f8056a3a354cf (diff)
refactor(tvix/glue): take &CAHash, not CAHash r/8306
We use a bit less cloning that way.

Change-Id: I28bf99577e4a481e35fbf99d0724adab5502a1bd
Reviewed-on: https://cl.tvl.fyi/c/depot/+/11874
Reviewed-by: Connor Brewster <cbrewster@hey.com>
Tested-by: BuildkiteCI
Reviewed-by: Ilan Joselevich <personal@ilanjoselevich.com>
Diffstat (limited to 'tvix/glue/src/tvix_store_io.rs')
-rw-r--r--tvix/glue/src/tvix_store_io.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/tvix/glue/src/tvix_store_io.rs b/tvix/glue/src/tvix_store_io.rs
index b0367f60aac7..4e5488067f8f 100644
--- a/tvix/glue/src/tvix_store_io.rs
+++ b/tvix/glue/src/tvix_store_io.rs
@@ -357,7 +357,7 @@ impl TvixStoreIO {
         &self,
         name: &str,
         path: &Path,
-        ca: CAHash,
+        ca: &CAHash,
         root_node: Node,
     ) -> io::Result<(PathInfo, NixHash, StorePath)> {
         // Ask the PathInfoService for the NAR size and sha256
@@ -372,7 +372,7 @@ impl TvixStoreIO {
 
         // Calculate the output path. This might still fail, as some names are illegal.
         let output_path =
-            nix_compat::store_path::build_ca_path(name, &ca, Vec::<String>::new(), false).map_err(
+            nix_compat::store_path::build_ca_path(name, ca, Vec::<String>::new(), false).map_err(
                 |_| {
                     std::io::Error::new(
                         std::io::ErrorKind::InvalidData,
@@ -399,7 +399,7 @@ impl TvixStoreIO {
         &self,
         name: &str,
         path: &Path,
-        ca: CAHash,
+        ca: &CAHash,
         root_node: Node,
     ) -> io::Result<StorePath> {
         let (path_info, _, output_path) = self.node_to_path_info(name, path, ca, root_node).await?;