diff options
author | Tobias Geerinckx-Rice <me@tobias.gr> | 2021-11-19 17:37:44 +0100 |
---|---|---|
committer | Tobias Geerinckx-Rice <me@tobias.gr> | 2021-11-27 00:49:53 +0100 |
commit | 1b1f557d888fa84b1bc818f1b221776355a7a2dd (patch) | |
tree | 60638369c4b7dc44ec769dc4412cb4aca01c6ca1 /nix | |
parent | 3887c1f3b3ee679042387c444aa663f67172cc66 (diff) | |
download | guix-1b1f557d888fa84b1bc818f1b221776355a7a2dd.tar guix-1b1f557d888fa84b1bc818f1b221776355a7a2dd.tar.gz |
daemon: Print the line whence we expect an integer.
* nix/libstore/local-store.cc (LocalStore::getLineFromSubstituter):
Include the malformed substituter stream line in the error message.
Diffstat (limited to 'nix')
-rw-r--r-- | nix/libstore/local-store.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/nix/libstore/local-store.cc b/nix/libstore/local-store.cc index d52b102343..0883a4bbce 100644 --- a/nix/libstore/local-store.cc +++ b/nix/libstore/local-store.cc @@ -839,7 +839,8 @@ template<class T> T LocalStore::getIntLineFromSubstituter(Agent & run) { string s = getLineFromSubstituter(run); T res; - if (!string2Int(s, res)) throw Error("integer expected from stream"); + if (!string2Int(s, res)) + throw Error(format("integer expected from stream: %1%") % s); return res; } |