about summary refs log tree commit diff
path: root/src/libutil/compression.hh
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2016-04-15T13·11+0200
committerEelco Dolstra <eelco.dolstra@logicblox.com>2016-04-15T13·39+0200
commitd1b0909894a302540f979d904dd378af1cad620c (patch)
tree691ec2d838e4449897549a537145971d9b12a3d5 /src/libutil/compression.hh
parent99851c6f06c80fe2222c5e5fcef963804e907170 (diff)
BinaryCacheStore::readFile(): Return a shared_ptr to a string
This allows readFile() to indicate that a file doesn't exist, and
might eliminate some large string copying.
Diffstat (limited to 'src/libutil/compression.hh')
-rw-r--r--src/libutil/compression.hh4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libutil/compression.hh b/src/libutil/compression.hh
index eb1697fc4a..79a796db77 100644
--- a/src/libutil/compression.hh
+++ b/src/libutil/compression.hh
@@ -1,11 +1,13 @@
 #pragma once
 
+#include "ref.hh"
+
 #include <string>
 
 namespace nix {
 
 std::string compressXZ(const std::string & in);
 
-std::string decompressXZ(const std::string & in);
+ref<std::string> decompressXZ(const std::string & in);
 
 }