summary refs log tree commit diff
path: root/nix/libutil/hash.cc
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2022-12-17 12:25:47 +0100
committerLudovic Courtès <ludo@gnu.org>2022-12-18 01:16:47 +0100
commit2d4d26769d6a3be1b21302b0bb2bd099fd55ccf8 (patch)
tree1b975e7063a14a4972852df5129befad57b159c2 /nix/libutil/hash.cc
parent239bfe2ec1fa3b4305500211e6cade6e4bda2a62 (diff)
downloadguix-2d4d26769d6a3be1b21302b0bb2bd099fd55ccf8.tar.gz
daemon: Make "opening file" error messages distinguishable.
* nix/libstore/build.cc (DerivationGoal::openLogFile): Customize
"opening file" error message.
* nix/libutil/hash.cc (hashFile): Likewise.
* nix/libutil/util.cc (readFile, writeFile): Likewise.
Diffstat (limited to 'nix/libutil/hash.cc')
-rw-r--r--nix/libutil/hash.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/nix/libutil/hash.cc b/nix/libutil/hash.cc
index 7853acdd49..9ba604eb85 100644
--- a/nix/libutil/hash.cc
+++ b/nix/libutil/hash.cc
@@ -244,7 +244,7 @@ Hash hashFile(HashType ht, const Path & path)
     start(ht, ctx);
 
     AutoCloseFD fd = open(path.c_str(), O_RDONLY);
-    if (fd == -1) throw SysError(format("opening file `%1%'") % path);
+    if (fd == -1) throw SysError(format("computing hash of file `%1%'") % path);
 
     unsigned char buf[8192];
     ssize_t n;