summaryrefslogtreecommitdiff
path: root/nix
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2026-05-30 15:01:59 +0200
committerLudovic Courtès <ludo@gnu.org>2026-08-17 16:47:35 +0200
commit6fbe87f2c890e10c6b24f838b73ad3683b5c97b0 (patch)
treebbdfe0b22b75d4f6d7dd2bb8609eaf25e1d7ba8e /nix
parent30d5740056fce43fede63237bb826f86a3237566 (diff)
daemon: Remove ‘requireSignature’ argument to ‘importPaths’.
For ‘guix-daemon’ the value of ‘requireSignature’ has always been true. * nix/libstore/store-api.hh (StoreAPI)[importPaths]: Remove ‘requireSignature’ argument. * nix/libstore/local-store.hh (LocalStore)[importPaths]: Likewise. * nix/libstore/local-store.cc (LocalStore::importPaths): Adjust accordingly. * nix/nix-daemon/nix-daemon.cc (performOp): Remove first argument to ‘importPaths’. Change-Id: I7ed87f3af03cca7078e224788114c499773f01c2 Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'nix')
-rw-r--r--nix/libstore/local-store.cc4
-rw-r--r--nix/libstore/local-store.hh2
-rw-r--r--nix/libstore/store-api.hh2
-rw-r--r--nix/nix-daemon/nix-daemon.cc2
4 files changed, 5 insertions, 5 deletions
diff --git a/nix/libstore/local-store.cc b/nix/libstore/local-store.cc
index 478f2ccc44f..3bb96e32601 100644
--- a/nix/libstore/local-store.cc
+++ b/nix/libstore/local-store.cc
@@ -1424,14 +1424,14 @@ Path LocalStore::importPath(bool requireSignature, Source & source)
1424} 1424}
1425 1425
1426 1426
1427Paths LocalStore::importPaths(bool requireSignature, Source & source) 1427Paths LocalStore::importPaths(Source & source)
1428{ 1428{
1429 Paths res; 1429 Paths res;
1430 while (true) { 1430 while (true) {
1431 unsigned long long n = readLongLong(source); 1431 unsigned long long n = readLongLong(source);
1432 if (n == 0) break; 1432 if (n == 0) break;
1433 if (n != 1) throw Error("input doesn't look like something created by `nix-store --export'"); 1433 if (n != 1) throw Error("input doesn't look like something created by `nix-store --export'");
1434 res.push_back(importPath(requireSignature, source)); 1434 res.push_back(importPath(true, source));
1435 } 1435 }
1436 return res; 1436 return res;
1437} 1437}
diff --git a/nix/libstore/local-store.hh b/nix/libstore/local-store.hh
index 23af8c3f029..754cdf5ad31 100644
--- a/nix/libstore/local-store.hh
+++ b/nix/libstore/local-store.hh
@@ -108,7 +108,7 @@ public:
108 void exportPath(const Path & path, bool sign, 108 void exportPath(const Path & path, bool sign,
109 Sink & sink); 109 Sink & sink);
110 110
111 Paths importPaths(bool requireSignature, Source & source); 111 Paths importPaths(Source & source);
112 112
113 void buildPaths(const PathSet & paths, BuildMode buildMode); 113 void buildPaths(const PathSet & paths, BuildMode buildMode);
114 114
diff --git a/nix/libstore/store-api.hh b/nix/libstore/store-api.hh
index bc90d145a29..29b33c0be9c 100644
--- a/nix/libstore/store-api.hh
+++ b/nix/libstore/store-api.hh
@@ -214,7 +214,7 @@ public:
214 214
215 /* Import a sequence of NAR dumps created by exportPaths() into 215 /* Import a sequence of NAR dumps created by exportPaths() into
216 the Nix store. */ 216 the Nix store. */
217 virtual Paths importPaths(bool requireSignature, Source & source) = 0; 217 virtual Paths importPaths(Source & source) = 0;
218 218
219 /* For each path, if it's a derivation, build it. Building a 219 /* For each path, if it's a derivation, build it. Building a
220 derivation means ensuring that the output paths are valid. If 220 derivation means ensuring that the output paths are valid. If
diff --git a/nix/nix-daemon/nix-daemon.cc b/nix/nix-daemon/nix-daemon.cc
index b3cdb699ac2..49172d53e9e 100644
--- a/nix/nix-daemon/nix-daemon.cc
+++ b/nix/nix-daemon/nix-daemon.cc
@@ -480,7 +480,7 @@ static void performOp(bool trusted, unsigned int clientVersion,
480 480
481 /* Unlike Nix, always require a signature, even for "trusted" 481 /* Unlike Nix, always require a signature, even for "trusted"
482 users. */ 482 users. */
483 Paths paths = store->importPaths(true, source); 483 Paths paths = store->importPaths(source);
484 stopWork(); 484 stopWork();
485 writeStrings(paths, to); 485 writeStrings(paths, to);
486 break; 486 break;